Tutorial : Confguring a micro SD memory card as both swap and storage area for the DragonBoard 410c (DB410C)

Similar documents
CST8207: GNU/Linux Operating Systems I Lab Nine Disks, Partitions, and File Systems Part 2. Disks, Partitions, and File Systems - Part 2 of 2

This is Worksheet and Assignment 12. Disks, Partitions, and File Systems

Changing user login password on templates

Adafruit's Raspberry Pi Lesson 1. Preparing an SD Card for your Raspberry Pi

Installation of the OS

Getting Started with BeagleBoard xm

XLink Kai Raspberry Pi Beginners Tutorial

Disks, Filesystems, Booting Todd Kelley CST8177 Todd Kelley 1

Raspberry Pi 2b PART 1. Table of Contents. Step by step guide. 1. Hardware (0:05) RS Online (ex-tax prices)... 3 MSY ebay...

Cross-compilation with Buildroot

OPS235. Linux File Systems Partitioning Mounting File Systems

Once your USB drive is formatted for the FAT32 file system it can be mounted and tested on the GESBC To do this, use the following command:

How To Resize ext3 Partitions Without Losing Data

The Ultimate Linux/Windows System

Idea6410 Ubuntu User Manual V 0.19

Chapter 6. Linux File System

Unless otherwise noted, all references to STRM refer to STRM, STRM Log Manager, and STRM Network Anomaly Detection.

imx6 Rex EMC testing Content

Zephyr Kernel Installation & Setup Manual

Lab E2: bypassing authentication and resetting passwords

(32 KB) 216 * 215 = 231 = 2GB

Project 3: An Introduction to File Systems. COP 4610 / CGS 5765 Principles of Operating Systems

Manually Mount Usb Flash Drive Ubuntu Server 12.04

Operating Systems Lab 1. Class topic: Installation of the operating system. Install Ubuntu on Oracle VirtualBox

By: Yushi Wang Partners: Shen Yue and Yubing Xu Group 6. How to Setup Pandaboard ES Software Environment for UAV Project

Manually Mount Usb Flash Drive Ubuntu Server

Partitioning and Formatting Guide

Disks, Filesystems 1

PiCloud. Building owncloud on a Raspberry PI

망고 210 ICS mmc booting 메뉴얼 작성및 patch

Ubuntu Manual Fsck Must Performed Debian

MINI-HOWTO backup and/or restore device or partition using zsplit/unzsplit

DUAL OS INSTALLATION

Windows Method Using Linux Live CD and Gparted

Manually Mount Usb Flash Drive Linux Command Line Redhat

3X Linux System Administration (Level 1) Exam.

Linux Manually Mount External Hard Drive Ntfs-3g Could Not

Adding a block devices and extending file systems in Linux environments

Lab2 - Bootloader. Conventions. Department of Computer Science and Information Engineering National Taiwan University

cpouta exercises

RH133. Red Hat Linux System Administration

CSN08101 Digital Forensics. Module Leader: Dr Gordon Russell Lecturers: Robert Ludwiniak

INTRODUCTION TO LINUX

Operating System. Hanyang University. Hyunmin Yoon Operating System Hanyang University

LotOS Framework. Getting Started Guide for Banana Pi. Copyright (C) 2015 ilbers GmbH Revision 1.1,

Lab #9: Configuring A Linux File Server

exam.30q. Number: Passing Score: 800 Time Limit: 120 min File Version: 1 LPI

Operating Systems Linux 1-2 Measurements Background material

ELE409 SPRING2018 LAB0

Using grub to Boot various Operating Systems

Vertica on Microsoft Azure HPE Vertica Analytic Database. Software Version: 7.2.x

TinyNet. Creating Virtual Machines

Getting Started with Pentaho and Cloudera QuickStart VM

Install and Configure Ubuntu on a VirtualBox Virtual Machine

Step-by-step guide for the libradtran virtual machine. A) Installation

Linux Manually Mounting External Hard Drive Mac Terminal

Linux Files and the File System

Week 10 Project 3: An Introduction to File Systems. Classes COP4610 / CGS5765 Florida State University

Introduction to Unix. Jin-Soo Kim Computer Systems Laboratory Sungkyunkwan University

Linux Manually Mount External Hard Drive Ntfs 3g Could Not

Disks, Filesystems Todd Kelley CST8177 Todd Kelley 1

Orchid Core VMS Installation Guide

MaRTE OS FAT16 Filesystem

Manually Mount Usb Flash Drive Ubuntu Not Recognizing

Project 3: An Introduction to File Systems. COP4610 Florida State University

Linux System Administration, level 1. Lecture 4: Partitioning and Filesystems Part II: Tools & Methods

1. Set up the storage to allow access to the LD(s) by the server following the NEC storage user guides.

This tutorial will guide you how to setup and run your own minecraft server on a Linux CentOS 6 in no time.

Davide Cavaliere 18 th February 2017

TestOut Linux Pro - English 4.0.x OBJECTIVE MAPPING: CompTIA Linux+ LX0-103

Vendor: RedHat. Exam Code: EX200. Exam Name: Red Hat Certified System Administrator - RHCSA. Version: Demo

How to securely isolate Damn Vulnerable Linux with VirtualBox

The Lecture's aim A preparation for the installation party: Prepare your computer for the installation Know what's going to happen Understand what's g

Experiments 1 How to set up Raspberry Pi B+ The little computer you can cook into DIY tech projects

Manually Mount External Hard Drive Win 7 Not Showing Up

Managing Disks. Managing Disks in the Cluster. Disk Requirements

SparkGate7 Quick startup guide

Linux. For BCT RE2G2. User Guide. Document Reference: BCTRE2G2 Linux User Guide. Document Issue: Associated SDK release: 1.

To enjoy the use of your Orange Pi PC, you will need at least the accessories in the table below. No. Item Minimum recommended specification & notes

Mac Os X Manually Mounted Usb Drive Read Only

EX200.redhat

Linux CompactFlash Re-imaging Procedure. April

MicroZed Open Source Linux In System QSPI Programming Tutorial

Privacy and Security in Online Social Networks Department of Computer Science and Engineering Indian Institute of Technology, Madras

Exam Name: Red Hat Certified Engineer on Redhat

Format Hard Drive After Install Ubuntu From Usb External

CST Algonquin College 2

Upgrading Prime Optical

fat ntfs librfs windows 98 ranfs.pdf help

Linux+ Guide to Linux Certification, Third Edition. Chapter 2 Linux Installation and Usage

LiLo Crash Recovery. 1.0 Preparation Tips. 2.0 Quick Steps to recovery

QPKG Debian6 V (Beta)

Magneto-Optical Disk Drive

Adafruit's Raspberry Pi Lesson 6. Using SSH

Linux File System Study Guide

User Manual V4.0. Element14 element14.com/pidesktop 1

INSTALLATION. Security of Information and Communication Systems. Table of contents

How to Recover Data with Linux

Manually Mount Usb Device Linux Command Line Ubuntu 12.04

SETTING UP SSH FOR YOUR PARALLELLA: A TUTORIAL FOR STUDENTS

Transcription:

Tutorial : Confguring a micro SD memory card as both swap and storage area for the DragonBoard 410c (DB410C) [1] Introduction The unboxing experience of the DragonBoard 410c is very enjoyable and straightforward. At frst, one must connect it to an HDMI monitor, keyboard and mouse and then power it on. In its factory confguration, the DB410C is shipped with Android operating system. Nevertheless, it's usual that some users may prefer to use other operating systems available for download. This tutorial is useful to those who opt for utilizing the Debian (Linaro) operating system. After refashing the DB410C with a new operating system, the next confguration step is likely to be the WiFi network parameters. With that accomplished, the DB410C is ready for use. However, the overall user experience with the DB410C will signifcantly enhance, should the user follow the instructions of this tutorial, which aim the add a micro SD memory card as both swap and extra storage for the board. [2] Required Items - 1 micro SD memory card (preferably, a fast one, such as the SanDisk Ultra ) with 16GB or larger capacity. [3] Procedure In this example, I'll be using a micro SD card with a capacity of 16GB (empty and previously formatted as FAT32). [3.1] Open a new Terminal Window (System Tools -> LXTerminal) [3.2] Check the device names $ ls /dev/mmc* The result will contain a list of names starting with "/dev/mmcblk0. [3.3] Insert the micro SD card in the DC410C slot (the micro SD card will probably be mounted automatically) [3.3.1] Recheck the device names $ ls /dev/mmc* At this time, the result must contain a list of several names starting with either /dev/mmcblk0 or /dev/mmcblk1. Note the diference between this result and that one from item [3.2]. Probably, the diference are those names starting with /dev/mmcblk1 (which are the disk partitions related to the newly inserted micro SD card). [3.3.2] Check the mounted disks names $ ls /media/linaro The result will contain a list of names of mounted disks in the DB410C.

[3.3.3] Check the link between devices and disks $ df -ht The result will contain a table with 7 columns and many rows. The columns of interest are the frst one (FileSystem) and the last one (Mounted on). The line related to the micro SD card will likely be the last one of this table. In my case, what I see is the following : FileSystem Type Size Used Avail Use% Mounted on /dev/mmcblk1p1 vfat 15G 2.7M 15G 1.00% /media/linaro/fat This means that the micro SD card has a device name /dev/mmcblk1 and its p1 partition is mounted in a directory named /media/linaro/fat (this name may difer a little, case-by-case). [3.3.4] Eject (unmount) the micro SD card $ sudo umount /media/linaro/fat [3.3.5] Verify whether the unmounting really happened $ df -ht Note that, at this time, the last line (related to the micro SD card) must have been gone.

[3.4] Repartition the micro SD card The name /dev/mmcblk1p1 means that the device /dev/mmcblk1 has a partition p1. Other partitions may also exist ( p2, p3, etc). In my case, what I see is a unique partition named /dev/mmcblk1p1. On the next steps, we'll repartition the micro SD. The goal is to create two new partitions: one named /dev/mmcblk1p1 and another named /dev/mmcblk1p2. Partition name Size Type of partition Function /dev/mmcblk1p1 3 / 4 of the available space Linux (83) Storage /dev/mmcblk1p2 1 / 4 of the available space Swap Linux (82) Swap We'll be using the command fdisk, which must be run as superuser (sudo). For this reason, be very careful while using it. $ sudo fdisk /dev/mmcblk1 The main options of the command fdisk are: option m p d n t w description Help Show partitions Delete a partition Add a new partition Change the type of a partition Save results and exit [3.4.1] Delete the existent partition type d [3.4.2] Create a new partition type n type p (type of partition : primary) type 1 (id of partition : 1) type 2048 or press enter (frst sector : 2048) At this time, a number will be shown (as default). In my case, the number is 31116287. Read this number and multiply it by 3/4. The result wil be 23337215. Type this number. type 23337215 (last sector : 23337215)

[3.4.3] Create a second partition type n type p (type of partition : primary) type 2 (id of partition : 2) press enter (frst sector : default = 23339008) press enter (last sector : default = 31116287) [3.4.4] Change the types of partitions type t type 1 (id of partition: 1) type 83 (type of partition : Linux) type t type 2 (id of partition: 2) type 82 (type of partition : Linux Swap / Solaris) [3.4.5] Verify results type p The result will be a table with 8 columns : Device Boot Start End Sectors Size Id Type /dev/mmcblk1p1 2048 23337215 23335168 11.1G 83 Linux /dev/mmcblk1p2 23339008 31116287 7777280 3.7G 82 Linux Swap / Solaris [3.4.6] Save results and exit type w [3.4.7] Check the names of the new devices $ ls /dev/mmc* Note that at the tail of the list there will be the following devices : /dev/mmcblk1 /dev/mmcblk1p1 /dev/mmcblk1p2 (micro SD card) (partition 1 : Linux) (partition 2 : Linux Swap)

[3.5] Format Linux partition We'll format the partition p1, create a mounting directory (/media/sdcard) and mount the device in this directory. $ sudo mkfs.ext3 /dev/mmcblk1p1 (format) $ sudo mkdir /media/sdcard (create directory) $ sudo mount -t ext3 /dev/mmcblk1p1 /media/sdcard (mount) [3.6] Confgure the Swap Linux partition We'll prepare the partition p2 as Swap area and mount it: $ sudo mkswap /dev/mmcblk1p2 (prepare) $ sudo swapon /dev/mmcblk1p2 (mount) $ sudo swapon -s (show status) [3.7] Create scripts for automating the mounting of partitions Using your preferred text editor, create the following fle (saving it as dragon_up.sh ) in a utility scripts folder : In my case, the utility scripts folder is : /home/linaro/documents/utils dragon_up.sh #! /bin/sh sudo mount -t ext3 /dev/mmcblk1p1 /media/sdcard sudo swapon /dev/mmcblk1p2 sudo swapon -s Similarly, create the fle below (saving it as dragon_down.sh ) : dragon_down.sh #! /bin/sh sudo umount /media/sdcard sudo swapof /dev/mmcblk1p2 Transform them into executable fles : $sudo chmod +x./dragon_up.sh $sudo chmod +x./dragon_down.sh

[3.8] The new partitions are ready for use Whenever needed, run the script dragon_up.sh to activate the new partitions, or the script dragon_down.sh to deactivate them. One interesting idea is to include the calling of the script dragon_up.sh in the Linux initialization (boot). [3.9] Automate the calling of the script just after the Linux boot (Optional) Certainly, your project will need to execute initialization scripts along with the boot (or just after it). In this example, we'll create a new script name mybootscript with this goal. Should your project already have a similar script, sufce to include a calling to dragon_up.sh into it. [3.9.1] Create the script mybootscript" Using your preferred text editor, create the following fle, saving it as mybootscript in the folder /etc/init.d /etc/init.d/mybootscript #! /bin/sh cd /home/linaro/documents/utils sudo./dragon_up.sh $sudo chmod 755 /etc/init.d/mybootscript $sudo update-rc.d mybootscript defaults $sudo service --status-all (transform into executable) (confgure the service) (show services status) From now on, just after the DB410C boot, the script mybootscript will run. In this example, this script calls the drangon_up.sh script which, in its turn, activates the partitions of the micro SD card. In this same mybootscript fle, it's possible to include other callings to diferent scripts of your project. [4.0] Conclusion Your DragonBoard 410c will have an optimized performance due to the new swap and storage partitions (directory /media/sdcard) of the micro SD card. You'll promptly notice the performance enhancement. With these new resources, it'll be possible to build large software packages from source code directly (or natively) in the DB410C, and much more swiftly. The user experience of the DB410C will be more enjoyable due to the possibility of several terminal windows or applications be simultaneously opened, with minimal overload to the operating system. Cezar Menezes cezar.menezes@live.com