Apr 21, 2017 0 Comments in Debian, Getting Start, Learning by
Booting Debian from a microSD

Using Debian OS is the best way to have a lot of software packages ready-to-use! So let’s see how to build a base system for your Cosino board.

First of all you need a new microSD with at least 4GB of free space (you can use a 2GB too, but if you start adding a lot of packages to it you may run out of free space).

warning Note: we strongly suggest to use a class 10 microSD!

Plug it into your host PC running a GNU/Linux base distribution (I’m using an Ubuntu 13.04 however these commands should work on most GNU/Linux distributions as well) and discover which is the microSD related device. For instance, after plugging in the microSD on my Ubuntu I run the dmesg command to discover:

so, on my system, the microSD is connected to the device /dev/mmcblk0 then I define the following environment variable:

however let’s consider that my laptop has a dedicated MMC port and on most systems with a MMC/USB adapter the device can be /dev/sdb (or /dev/sdc, /dev/sdd, etc.). In fact by using dmesg you can get something like:

so the environment variable defined above should be redefined as:

Well, now we need to download Cosino’s bootloaders, kernel and root filesystem images. All needed file are available on GitHub:

Now go to data directory ad use the build_sd.sh tool as shown below:

Let’s check if the chosen device is correct and, if OK, strike ENTER key otherwise use CTRL-C to stop here.

Ok, now just remove the miscroSD from your PC and plug in it into your Cosino board and then power up the system. You should see something as follow on your serial console:

Now you can login as root with password root.

Please, note that your new Debian OS is very basic, so you need to add packages according to suite your needs. You can take a look at this tutorial in order to know how to (basically) manage your new Debian system.

FAQ

1) During a package installation my root partition vanished! What’s happened?

Consider using a class 10 microSD.

2) I build up my microSD following this guide but when I put it into my Cosino based board it doesn’t do the boot sequence! What can I do?

Consider using a class 10 microSD.

Facebooktwitterlinkedin
Tags: