DoudouLinux DoudouLinux

The computer they prefer!

The site's languages [ar] [de] [en] [es] [fr] [it] [ms] [pt] [pt_br] [ro] [ru] [sr] [zh]

Home page > English > Documentation > Advanced tools > Creating a DoudouLinux USB key

Creating a DoudouLinux USB key

November 2010 — last update February 2011

All the versions of this article: [Deutsch] [English] [français] [italiano] [Bahasa Malaysia] [română] [русский]

Share with Digg Share with Reddit Share with Twitter Share with Facebook Share with YCombinator Share with DZone Share with Slashdot Share with StumbleUpon Share with Del.icio.us Yoolink LinkedIn

As indicated on the page Get DoudouLinux, once you have downloaded the image file for the USB key version, simply copying this file onto an USB key will not give you a working DoudouLinux USB key. You must use a special tool which will create a copy of the hard disk structure embedded in the downloaded image file directly onto the USB key. This operation will definitively erase the whole content of the target USB key. Thus, if you are not familiar with this kind of operation, you must know that there is a risk to choose a wrong disk as the target disk, loosing all data stored on your machine…

To avoid this, if you do not know how to manually perform the operation described at the end of this page, you can use a tool that we specially developed to make the creation of a DoudouLinux USB key as simple as possible. This tool, named “liveusb-write”, is shipped within DoudouLinux so that you do not need to install additional software. All you have to do is to burn a DoudouLinux CD in order to start the system. On the other hand, you can use this tool on any Linux computer [1] by downloading the Debian package [2] or by downloading the Python script directly from our source code repository.

1- Creating the key using liveusb-write

This tool operates in two modes:

  • the wizard mode, with a minimum number of question
  • the expert mode, which allows the user to choose everything that can be chosen

Operating in wizard mode, the tool automatically detects the USB keys and proposes to create a DoudouLinux key using one of the USB keys found. Because the size of most USB keys is bigger than the size needed to write those 700 MB of DoudouLinux, the tool will create for you another partition, which will host a file that will make possible the activation of data persistence for users. This second partition will be not filled up, so you will be able to use it to store additional data [3]. If you wish to activate user data persistence as well as system data persistence, you have to use the expert mode instead [4].

1.1- Wizard mode

If you wish to use the tool shipped within DoudouLinux, you can start it from The Whole DoudouLinux activity, from the application section Settings → System. If you installed the Debian package, you can find the executable in the Administration menu. Finally, if you downloaded the Python script, you have to run it from a console. The wizard mode progress is the following (see the pictures below):

  1. the user chooses the disk image file that is to be written onto the USB key
  2. choice of disk
    1. if only one USB key is detected, it will be proposed as a destination
    2. if several USB keys are detected, a list will be displayed allowing the user to choose
    3. if no USB key is detected, a message will be displayed inviting the user to connect an USB memory device, in order to avoid the use of the internal hard disk
  3. a confirmation window summarizes all operations that are about to be done
  4. data are written, please note that the application does not display anything on screen, no window is displayed until the task is completed

Once the operations are finished, a window informing you that the job is completed is displayed. Usually the USB device is immediately available.

Important notice: if you execute liveusb-write from the DoudouLinux CD, you have to locate your disk image file using the file manager before actually launching the tool. This is required because the disks are not visible by default in DoudouLinux and only the file manager can make them appear. Please read the page Using an USB key or an USB hard disk in order to obtain more information about making your disks appear. The image file should be hosted in a sub-folder of the /media folder as shown bellow.

PNG - 32.9 kb
Sélection d’un fichier d’image disque à écrire (sur la clef)
PNG - 14.5 kb
Message résultant de la détection des disques USB
PNG - 16.7 kb
Confirmation de la création de la clef USB avec persistance

1.2- Expert mode

To run the tool in expert mode, you have to use the console and type the following command:

sudo liveusb-write --expert

The operation also begins by choosing the disk image file that is to be written. The full list of storage devices is presented, showing external devices as well as internal hard disks. The next step is to choose the kind of data persistence you wish to use (user data with or without system data) and the size of the persistence file. The size must be specified in megabytes but without unit. Finally, the operation in wizard mode will start after you agree in a confirmation window.

PNG - 13.9 kb
Sélection du disque dans le mode expert
PNG - 15 kb
Sélection du type de persistance dans le mode expert
PNG - 10.8 kb
Sélection de la taille de persistance dans le mode expert

2- Manual mode

In the case of Unix-like systems (Linux, Mac OS X), the necessary tools are natively installed so that you do not need to install additional software. Concerning Windows® systems, you have to download a tool equivalent to the dd command. It seems that there is a Windows® version, but we have never tested it. This is why we refer to Linux systems in the following example.

The typical command used to copy a disk image file onto an USB key is:

dd if=doudoulinux-2010-11-uk.img of=/dev/sdx

where /dev/sdx is the identifier of your USB key (it can be /dev/sda, /dev/sdb, etc., depending on the computer configuration). To find out what is the right path, you can either display the end of dmesg just after the USB key is connected, or display the disk list with the fdisk tool.

Using dmesg :

$ dmesg | tail
[  692.782396] sd 6:0:0:0: Attached scsi generic sg2 type 0
[  692.785890] sd 6:0:0:0: [sdb] 2066944 512-byte logical blocks: (1.05 GB/1009 MiB)
[  692.786376] sd 6:0:0:0: [sdb] Write Protect is off
[  692.786384] sd 6:0:0:0: [sdb] Mode Sense: 0b 00 00 08
[  692.786389] sd 6:0:0:0: [sdb] Assuming drive cache: write through
[  692.788629] sd 6:0:0:0: [sdb] Assuming drive cache: write through
[  692.788640]  sdb: sdb1
[  692.791250] sd 6:0:0:0: [sdb] Assuming drive cache: write through
[  692.791257] sd 6:0:0:0: [sdb] Attached SCSI removable disk
[  693.458633] FAT: utf8 is not a recommended IO charset for FAT filesystems, filesystem will be case sensitive!

Using fdisk :

$ sudo fdisk -l

Disk /dev/sda: 250.0 GB, 250059350016 bytes 255 heads, 63 sectors/track, 30401 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x80d2f3ee

Device Boot Start End Blocks Id System /dev/sda1 * 1 31 248976 83 Linux /dev/sda2 32 30401 243947025 8e Linux LVM

Disk /dev/sdb: 1058 MB, 1058275328 bytes 2 heads, 63 sectors/track, 16404 cylinders Units = cylinders of 126 * 512 = 64512 bytes Disk identifier: 0x021a1d62

Device Boot Start End Blocks Id System /dev/sdb1 * 1 16405 1033456 6 FAT16

All you have to do now is to make the right choice!

Footnotes

[1] We have never tested, but the script does not call any software specific to a given distribution. However you need to install the tools that the script requires: zenity, fdisk, squashfs-tools, time, python-unac.

[2] It should work on all Linux systems derived from Debian, e.g. Ubuntu.

[3] This is a FAT type partition, specific to Windows® systems, to be sure it can read it (all other systems can do it, of course).

[4] You can also rename the file created onto the second partition as live-rw-doudoulinux.


identica logo facebook logo google+ logo
Geographical location of visitors
DoudouLinux logo Debian logo TSPU logo Genesi logo
Creative Commons Copyright © DoudouLinux.org team - All texts from this site are published under the license Creative Commons BY-SA
SPIP | template | Site Map| Follow-up of the site's activity RSS 2.0