Blog L’Ordikc

4 September 2008

Mandriva One USB – Eng

Filed under: Non classé — lordikc @ 22:22

This is a very short howto turn a mandriva one (KDE or GNOME) into a bootable USB device.

New: See this article for enabling persistence.

How to prepare the USB key to receive mandriva one

USB key are often initialised with a strange partition table. This must be corrected to install mandriva one and be ab le to boot.

With Linux

Use the fdisk partitionning tool to remove former partitions, create a new one and make it bootable.
First identify the device of the USB key with cat /proc/partitions. Let say it’s /dev/sdc.

major minor  #blocks  name

   8     0    3907512 sda
   8     1    3903763 sda1
   7     0     990320 loop0
   8    32    4029952 sdc
   8    33    4024251 sdc1

Launch fdisk this way :

fdisk /dev/sdc

Use the d commande to delete former partition until there are no more partition left. Be aware that it will erase data on your USB Key!

Use the n commande to create a new partition (example are in french but you should have similar results in english, I don’t have an english configuration but feel free to send me your results):

Commande (m pour l'aide): n
Action de commande
   e   étendue
   p   partition primaire (1-4)
p
Numéro de partition (1-4): 1
Premier cylindre (1-501, par défaut 1): (just type return)
Utilisation de la valeur par défaut 1
Dernier cylindre ou +taille or +tailleM ou +tailleK (1-501, par défaut 501): (just type return)
Utilisation de la valeur par défaut 501

Use the a command to toggle the bootable flag.

Commande (m pour l'aide): a
Numéro de partition (1-4): 1

Use the t command to change partition type to W95 FAT32:

Commande (m pour l’aide): t

Partition sélectionnée 1
Code Hex (taper L pour lister les codes): b
Type de partition système modifié de 1 à b (W95 FAT32)

Finally use the p commande to display current partition table state:

Commande (m pour l'aide): p

Disque /dev/sdc: 4126 Mo, 4126670848 octets
255 heads, 63 sectors/track, 501 cylinders
Units = cylindres of 16065 * 512 = 8225280 bytes
Disk identifier: 0xf27e10b5
Périphérique Amorce    Début         Fin      Blocs    Id  Système
/dev/sdc1   *           1         501     4024251   b  W95 FAT32

Quit fdisk with the w commande.

I never needed this step but you can give it a try (syslinux must be installed) :

# dd if=/usr/lib/syslinux/mbr.bin of=/dev/sdc

Format the key with the following commande:

mkdosfs /dev/sdc1 -n MANDRIVAONE

Key is ready.

With Windows

Use this tool and set label to MANDRIVAONE (upper case).

Installation

If you didn’t followed the previous steps, set the label to MANDRIVAONE (all upper case).

Download the corresponding kit below and uncompress it at the root of the USB device. This file contains a initrd.usb, syslinux.cfg and /boot/vmlinuz file.

Note : Since version 2009, mandriva one car really be used to install the final system. It removes unused internationalisations and drivers.

Download the mandriva one 2009 iso and copy file /CDROM/loopbacks/distrib-lzma.sqfs to /USB/loopbacks/distrib-lzma.sqfs. (You can mount the iso image without burning a CD with : mount file.iso /mnt -o loop. Use 7-Zip for windows).

Use syslinux to turn the USB device into a bootable linux system :

Windows> syslinux -mf X:
Linux> syslinux -f /dev/sdc1

Where X is the USB letter for windows or the partition device for linux.

If you are satisfied with Mandriva 2009, you can try this tutorial to install Mandriva 2009 LXDE from USB Key.

It seems that syslinux V3.72 doesn’t work. If you face problem booting you may want to try with an older one.

Troubleshoot

If it doesn’t work, please reports:

  • You used linux or windows install ?
  • Your hardware both computer and usb key.
  • Language used on your computer.
  • Description of the boot sequence from turn on computer, hit key XXX to have boot menu, to error message

Most of the time it’s due to bad key preparation or bad typing when labeling the usb key.

What’s next

You may wan’t to try this step by step tutorial on how to install Mandriva 2009 Free with the LXDE (Lightweight X11 Desktop Environnement) from a USB Key for. The guide is full of snapshot to ease the installation process.

If you have a SSD NetBook (EEE-PC 4G for instance), you may wan’t to compress /usr in order to save more than 1GB.

You may wan’t to install mandriva on a USB key.

101 Comments »

  1. [...] English Francais [...]

    Pingback by Blog L’Ordikc » Mandriva one 2009 rc1 sur USB — 5 September 2008 @ 19:55

  2. I tried to install the mandriva-linux-one-2009-rc1-KDE4-int-cdrom-i586.iso this way, but at the point of copying cdrom loopback into usb loopback there’s a problem. There isn’t the directories in the iso for them. Only loopbacks directory with the distribs file in it.

    I have tried to install it on the eee using unetbootin but the installer errored with an inet.d/rcS error

    j’ai essayer a installer avec mandriva-linux-one-2009-rc1-KDE4-int-cdrom-i586.iso mais quand tu dit copier entre cdrom et usb il n’existe pas. Il existe un dossier loopbacks seulement et dans le fichier le distribs fichier.

    qu’est-ce qu’on fait?

    merci

    Comment by Brent — 7 September 2008 @ 15:48

  3. [...] Nouveau : Voir la page dédiée à Mandriva One USB. New : See dedicated page for Mandriva One USB. [...]

    Pingback by Blog L’Ordikc » Mandriva one 2008.1 sur USB — 7 September 2008 @ 18:47

  4. I don’t understand what is the problem. Download the iso file and do as root :

    # mount mandriva-linux-one-2009-rc1-KDE4-int-cdrom-i586.iso /mnt/disk -o loop
    # ls -l /mnt/disk/loopbacks/
    total 698524
    -rwx—— 1 root root 715288576 2008-09-03 13:02 distrib-lzma.sqfs

    This file should be copied to /YourUsb/loopbacks

    Comment by lordikc — 7 September 2008 @ 22:10

  5. http://forum.eeeuser.com/viewtopic.php?pid=372071#p372071

    Brilliant! Thanks!
    Can you explain how you create these “kits”? (the initrd.usb etc)

    Comment by Nick Brown — 9 September 2008 @ 14:24

  6. Hi,

    Thanks for providing these usb kits.
    It would be great if you could explain how these are created?
    Do you use draklive to (which I believe is used to create the ISO) to create the usb initrd etc?

    Comment by Nick Brown — 9 September 2008 @ 22:09

  7. The reason I ask how to recreate these kits is that I would like to test with a new kernel from mandriva cooker on my eee pc 901 to see if wireless is fixed and that requires a new initrd
    https://qa.mandriva.com/show_bug.cgi?id=42944
    Thanks Nick

    Comment by Nick Brown — 10 September 2008 @ 21:00

  8. I add the usb and code page modules in the initrd and the boot procedure. It depends from one version to the other so I just can’t describe it for sure.

    Comment by lordikc — 10 September 2008 @ 21:38

  9. Hi,

    how to create the kit for mandriva one 2009 rc2?

    Thanks in advance,
    Alexandre

    Comment by Alexandre — 26 September 2008 @ 11:06

  10. There is a kit for rc2?

    Comment by cicciocant — 26 September 2008 @ 12:35

  11. Hello. Is there a kit for rc2?

    Comment by cicciocant — 26 September 2008 @ 14:24

  12. The final release is due to 2008/10/09. I won’t have time to create a kit for rc2 before final release.

    Comment by lordikc — 27 September 2008 @ 2:20

  13. [...] Francais English [...]

    Pingback by Blog L’Ordikc » Mandriva one 2009 rc2 sur USB — 1 October 2008 @ 10:40

  14. Hi.
    I’m tried with 2009 rc2.
    When booting, the message is:

    SYSLINUX 3.11 0×4639e756 EBIOS Copyright (C) 1994-2005 H. Peter Anvin
    boot:
    Could not find kernel image: /boot/vm.lin
    boot:
    …..

    What is wrong?

    Thanks

    Comment by Stein — 1 October 2008 @ 14:32

  15. I must say I really don’t know. Are you sure you didn’t altered syslinux.cfg ? It should be looking for /boot/vmlinuz.

    Comment by lordikc — 2 October 2008 @ 12:36

  16. @Stein :
    It’s a problem due to syslinux. I had the same after installing syslinux from debian repository on my eeepc.
    Download V3.71 from http://www.kernel.org/pub/linux/utils/boot/syslinux/
    (The binary file is in Linux folder).

    V3.72 seems not to work on eeepc.

    Comment by KeeRooL — 9 October 2008 @ 10:25

  17. We Wait the kit for final release of Mandriva.

    Big thanks for your work Lordick

    Comment by cicciocant — 9 October 2008 @ 20:05

  18. lordikc: thanks for this, and I hope you don’t mind that I’m directing people here when they ask about USB One :) . Will you be doing a 2009 final?

    Comment by Adam Williamson — 9 October 2008 @ 23:40

  19. Will this work for the 2009.0 final release?

    Comment by Eric — 10 October 2008 @ 10:31

  20. I tried 2009 on my big laptop. I want to install it in my EEEpc, can you pls post the howto with the Mandriva 2009 final released on 9th Oct.?

    Comment by Sid — 11 October 2008 @ 4:19

  21. I tried your newest tgz-set for the mandriva one 2009 final release and once again followed each of the steps above, but I only get “Missing operating system” trying to boot. System is the Medion akoya mini E1210 (equivalent to the MSI Wind U100).

    Comment by Michel1980 — 11 October 2008 @ 9:41

  22. @Michel1980 : Can you give more details ? What king of usb key ? During the boot do you have the syslinux prompt ? Does it load the kernel and the initrd ?
    See comment #16 from KeeRooL it may help.

    Comment by lordikc — 11 October 2008 @ 9:51

  23. Thanks for immediate answer. I get neither a syslinux-prompt (i got it when trying rc2) nor kernel and the initrd are laoded. I tried to create the key from a windows system, with rc1/2 it worked. The USB Key is an EMTEC (BASF) 2 GB key formatted in FAT32.

    Comment by Michel1980 — 11 October 2008 @ 9:58

  24. Add: With RC1 and 2 creating the bootable partition with Syslinux 3.72 worked. I will try it once again with Syslinux 3.71 now.

    Comment by Michel1980 — 11 October 2008 @ 10:02

  25. @Michel1980 If you don’t see the prompt it’s either a syslinux, hardware or bad key preparation (or compatibility) issue.

    Comment by lordikc — 11 October 2008 @ 10:28

  26. I tried now creating the Linux System with SysLinux-3.71 (Win32 version – Operating System is Win XP Home). Result is the same: I only get the message “No operating system”. I neither get a syslinux prompt nor the kernel and the initrd are loaded. USB key is a 2 GB EMTEC key (BASF). Seems my last post here somehow was deleted or dissappeared…

    Comment by Michel1980 — 11 October 2008 @ 10:30

  27. After multiple formatting the key in FAT and back in FAT32 i finally got the key booting. After the Mandriva screen i have following error now: Cannot run ‘/etc/init.rd/rcS’: no such file or directory

    What is to do?

    Comment by Michel1980 — 11 October 2008 @ 11:15

  28. I’ve had the same experience as Michel1980. Trying to install on an Acer Aspire One netbook, tried syslinux 3.70, 3.71, 3.72. In all cases the ‘missing operating system’ is briefly displayed before the next boot device is tried.

    Comment by Gary — 11 October 2008 @ 13:14

  29. Can anyone who has been able to get the final Mandriva release to work please post and describe how they did it?

    Comment by Gary — 11 October 2008 @ 13:16

  30. It do work with EEE-PC 701 with a 2GB PNY USB KEY.

    Comment by lordikc — 11 October 2008 @ 13:58

  31. Thanks very much for this effort..

    No joy. Booting on 2009.1 Live Final. EeePC-901. Same on a generic Turion Laptop, and a Gateway tower.

    Splash page of Mandriva.. nothing more. Eventually text console. Somewhere along the way linuxrc must have barked, since no /proc mounted, udev never got going, cannot find any filesytem LABEL=MandrivaOne..etc.

    Any way to PREVENT! that stupid splash graphic from preventing any diagnostic info gathering?

    Comment by David Updegraff — 11 October 2008 @ 16:53

  32. @David Updegraff : Be sure to set label all upper case MANDRIVAONE

    Comment by lordikc — 11 October 2008 @ 16:58

  33. I tried with a lowcost 8GB EMTEC USB stick with an old K8N ASUS motherboard and it works.
    The booting process is very sensitive follow very carrefully the tutorial and it should work just fine.

    Comment by lordikc — 11 October 2008 @ 17:19

  34. [...] Mandriva released its 2009 final release. See this tutorial. [...]

    Pingback by Blog L’Ordikc » Mandriva one 2009 USB — 11 October 2008 @ 17:30

  35. Hi, I folowed all steps with this iso:
    mandriva-linux-one-2009-KDE4-int-cdrom-i586.iso

    And after the boot, I get:
    “cannot run ‘/etc/init.d/rcS’: No such file or directory

    After that it’s start to say: “device descriptor read/8, error -110″

    Any tip?

    Comment by Paulo Cesar — 11 October 2008 @ 17:49

  36. Tried with another usb device.. Same error, but now without the “device descriptor read/8, error -110″

    Comment by Paulo Cesar — 11 October 2008 @ 18:04

  37. It worked very well, thanks

    Comment by sid — 11 October 2008 @ 18:04

  38. SOLVED!

    Even though label on USB filesystem partition was ‘MANDRIVAONE’ the mount LABEL=”MANDRIVAONE” line kept failing. Do not know why. When I adjusted /linuxrc to hardwire mount the /dev/sdc1 that I could see was there, it worked ok.

    Thanks again for your helpful work.

    Comment by David Updegraff — 11 October 2008 @ 18:17

  39. David Updegraff can you explain me in simple words how to get the usb pen with mandriva working? I also get only splash screen and the console after.
    Thank you very much.

    Comment by Roberto — 11 October 2008 @ 21:11

  40. Ok, here I go again… It worked fine on my desktop computer, but on my Eee701 it gives this error:
    cannot run ‘/etc/init.d/rcS’: No such file or directory

    Comment by Paulo Cesar — 11 October 2008 @ 22:05

  41. @Paulo Cesar: Very strange. It’s orking on my EEE701 and it have been reported to work with other EEE701.
    Have you tried the other USB port of your EEE?

    Yesterday I thought of a localization issue since I had to add the nls_cp437 codepage in the initrd but since it’s working on one of your computer it shouldn’t be the case.

    Comment by lordikc — 12 October 2008 @ 9:45

  42. I have an EEE901 and I keep getting a “missing operating system error.” I’ve followed the tutorial exactly as far as I can tell, but I had to use v2.1.8 of the HP formatting tool (where the download link goes), not v2.0.6 as shown in the picture. I have a generic 2GB USB stick. I tried with syslinux 3.71, 3.70, and 3.63. Any suggestions?

    Comment by Patrick — 12 October 2008 @ 10:18

  43. I had problems with the usb stick (”/sbin/mingetty not found” during boot) and tried SD card for Mandriva One 2009 Final installation. No problems with SD card. It started from the very first time. Eee PC 701, BTW.

    Comment by Peter Kurishev — 12 October 2008 @ 11:55

  44. I’ve just uploaded a new version with more code pages. Give it a try.

    Comment by lordikc — 12 October 2008 @ 13:12

  45. Tried with the new kit.. Same problem..

    * You used linux or windows install ?
    Linux (archlinux to be more exact)

    * Your hardware both computer and usb key.
    EeePC 701 4G
    Kingston DataTraveller (tried with two of them, one 1GB and other 4GB)

    * Language used on your computer.
    I’m brazillian, but my Arch Linux is in english

    * Description of the boot sequence from turn on computer, hit key XXX to have boot menu, to error message
    I hit ESC like a crazy, the menu appears, I choose “Kingston DataTravaller” and it shows syslinux 3.71 screen. I hit enter and it starts to boot. On my main computer it shows a spash screem, but on Eee it doesn’t, and it fails with the folowing error:

    SQUASHFS error: sb_bread failed reading block 0×0
    SQUASHFS error: unable to read superblock
    Freeing unused kernel memory: 364k freed
    init started: BusyBox v1.6.1 (2008-05-16 12:38:44 UTC) multi-call binary
    Cannot run ‘/etc/init.d/rcS’ : No such file or directory

    Please press Enter to activate this console.

    ps: this isn’t my error, i found on the internet from a guy trying to install mandriva 2009 on a eee901 (http://www.linuxquestions.org/questions/mandriva-30/installing-mandriva-2009-rc2-on-eee-901-672586/)

    Comment by Paulo Cesar — 12 October 2008 @ 13:55

  46. Hoho it works now!

    I saw that it was detecting the card reader before this error, and detecting the datatraveler AFTER the error, so I tried to remove my sd card, same error, and then I disabled card reader on bios, now it works!

    thanks for the help and the kits :)

    Comment by Paulo Cesar — 12 October 2008 @ 14:08

  47. I tried the new kit and I still have the same problem. I’m using an EEE901 and doing the formatting in Windows XP. I’m using v.2.1.8 of the HP formatting tool, syslinux 3.71, and the Mandriva CD linked here. Everything is in English.

    When I start the computer, I press the escape key at the gray screen. I choose the USB drive from the list. Then I get a “missing operating system” error.

    Comment by Patrick — 12 October 2008 @ 23:16

  48. My netbook: MSI wind
    It works with final release of Mandriva 2009

    @KeeRooL
    Thanks for help

    Big thanks for your work Lordick

    Comment by Stein — 13 October 2008 @ 1:43

  49. @Patrick If you don’t see the syslinux prompt then you may have missed the syslinux step.

    You can try syslinux -smf X:

    Comment by lordikc — 13 October 2008 @ 6:18

  50. [...] и по-этому субботу я потратил на то, чтобы найти вот это замечательное руководство для англоязычной аудит…. Весь мой опыт будет основываться на [...]

    Pingback by Хороший, плохой, злой : Mandriva Linux One 2009.0 @ Eee PC — 13 October 2008 @ 11:58

  51. Tried syslinux 3.72 didn’t work, but it did work with syslinux 3.70.

    Comment by chuckcalo — 13 October 2008 @ 14:43

  52. [...] ad utilizzare Unetbootin, ma non c’è stato nulla da fare, così cercando in giro ho trovato una guida che sembrava risolvere il problema dell’installazione su pendrive, ma non c’è stato [...]

    Pingback by Mandriva 2009 su Asus Eee PC 701 — 13 October 2008 @ 21:47

  53. Using Windows, I was having a few of the issues posted here; the “missing operating system” error, as well as the “freeze splash screen/Cannot run ‘/etc/init.rd/rcS’: no such file or directory” error. What ended up working for me was this:

    1)Download Unetbootin (http://unetbootin.sourceforge.net/), the MandrivaOne iso, and Lordikc’s 2009 final kit.
    2)Using Unetbootin, set up your USB/flashdrive with the MandrivaOne iso as your source.
    3)After you exit Unetbootin, copy all the files from Lordikc’s kit. Say “Yes” to overwriting all the files. This step might seem unnecessary, but Unetbootin alone left me with the “rcS” hang error, so don’t skip it!

    It probably sounds stupid, but it worked for me. Maybe someone else will have similar luck?

    Comment by CS Weldon — 13 October 2008 @ 23:28

  54. Maybe someone who managed to have a working key could share an image of his key.
    Then the procedure would be as simple as :
    dd if=mandrivaoneusb.img of=/dev/sdc

    Comment by KeeRooL — 14 October 2008 @ 16:15

  55. CS Weldon it works!! Finally I have mandriva loading on my eee 1000H

    Thanks everyone!

    Comment by Galego — 14 October 2008 @ 16:41

  56. new error… INIT: cannot execute “sbin/mingetty”

    Comment by Galego — 14 October 2008 @ 16:45

  57. Thanks a lot for this Howto :)

    Final realease Mandr 2009 works well on my Aspire One, almost all out of the box, but not the microphone. Anyone knows a workout for getting the mic to function?

    Comment by Torstein — 15 October 2008 @ 0:18

  58. Galego! Try to use another USB port or change installation media from usb stick to SD card.

    Comment by Peter Kurishev — 15 October 2008 @ 11:19

  59. KeeRooL:

    I’ve made a little article in Russian here: http://peter.infosreda.com/ru/2008/10/13/mandriva-linux-one-2009-eee-pc

    There is also a link at the end of article for the complete image. But it is huge (1.4 Gb) and my outgoing channel is not very wide. I can put it on FTP of yours if you would like.

    Comment by Peter Kurishev — 15 October 2008 @ 11:31

  60. CS Weldon’s additional steps worked for me.

    Comment by Patrick — 15 October 2008 @ 15:55

  61. [...] it and paste it on your pendrive’s root, replacing the existing files. The kit is provided by ordikc, who wrote a great and extensive article about Mandriva One’s [...]

    Pingback by Installing mandriva 2009 on the Eee Box — 16 October 2008 @ 10:29

  62. Works with Panasonic Toughbook CF-18.
    Wifi OK
    Graphic Card/3D OK
    Son OK

    Comment by lordikc — 16 October 2008 @ 17:24

  63. As CSWeldon posted, I too was able to get the final version of Mandriva 2009 working by running the ISO on Unetbootin, with my USB drive formatted with the label Mandriva one, and then I used Lord’s kit to overwrite the files on the USB key after they were copied from Unetbootin.

    Comment by pHDeeZ — 20 October 2008 @ 0:54

  64. Great article. I followed the steps and everything worked. I installed it on my EEEPC 900. Many Thanks!!!

    Comment by Kais Hassan — 20 October 2008 @ 6:23

  65. @Windows users: As anybody tried to check the create a DOS startup disk toggle with internal MS-DOS ?
    I wonder if it toggle the bootable flag.

    Comment by lordikc — 20 October 2008 @ 7:44

  66. @Galego: “new error… INIT: cannot execute “sbin/mingetty”” Did you find a solution to this problem? I have the same issue…

    Comment by nedbenj — 21 October 2008 @ 15:20

  67. [...] and Mandriva One KDE cd image. I had some problems booting from flash drive, but fortunately this post was helpful for me. Although almost everything is working out-of-the-box (including Wifi, Wifi [...]

    Pingback by Mandriva One 2009 « mike’s weblog — 29 October 2008 @ 20:58

  68. Comment from CS Weldon worked for me!
    Thanks a lot

    Comment by Amr Hamdy — 4 November 2008 @ 0:05

  69. [moved to french zone]
    http://lordikc.free.fr/wordpress/?page_id=144

    Comment by cricx — 4 November 2008 @ 14:35

  70. [...] may want to boot this to clean /tmp, /var/tmp and [...]

    Pingback by Blog L’Ordikc » Using tmpfs with mandriva 2009 — 10 November 2008 @ 13:14

  71. Thanks to you, lordikc, I succeeded in booting Mandriva one 2009.0 from my USB Flash with your great tip!

    As additional information, I was able to install the Live Mandriva without formatting and modifying my drive with fdisk from Linux(Fedora) – I used only Gparted and syslinux installer in order to change the drive’s flag and to install a boot loader(to do so, of course, the drive has to be formatted with FAT before the operation. But almost all the drives are formatted with FAT by the time they are shipped from vendors, no one has to worry about it;) ).

    My Environment is:
    CPU: Intel Celeron D 330 (2.66GHz)
    RAM: 512MB
    MB: MSI P4MAM-V (with VIA’s P4M266A chipset)
    FlashDrive: SanDisk Cruzer colours+ 2GB
    (NOTE: This drive is available only in Japan.)
    ISO file which I used: mandriva-linux-one-2009-GNOME-jp-zh-cdrom-i586.iso

    Comment by makm — 14 November 2008 @ 15:03

  72. What about persistent changes to use the pendrive and save all the changes made to the system?
    I’ve found a script for MCNLive (mandriva 2007) to create a loop file, but it doesnt work on madriva 2009.
    Can somebodi modify it to work with mandriva 2009?

    the script:

    #!/bin/sh
    # Create mcnlive.loop
    # (C) 2007 Chris & Michel & Maurice mandrivaclub.nl
    # License GPL 2.0 or later

    #### Check for root ####
    if [ "$UID" != "0" ]; then
    echo “This script must be run as root.”
    exit
    fi

    # Set script title
    TITLE=”Create mcnlive.loop”
    ## Constants
    DIALOG=zenity
    ERROR=”Create mcnlive.loop”
    TMP=”/tmp/mcnloop.tmp”
    echo ” ” > $TMP

    #### Report error and exit
    error() {
    $DIALOG –info –text=”$1″ –title=”$ERROR”
    }

    goodbye() {
    exit 0
    }

    #### Command
    cmd() {
    echo “> $1 ” >> “$TMP”
    $1 2>”$TMP”
    OK=$?
    RESULT=”$(>”$TMP”
    if [ "$OK" != "0" ]; then # Delft, we have a problem
    if [ "$3" = "WARN" ]; then
    $DIALOG –warning –text=”$2″
    elif [ "$3" = "STOP" ]; then # Bad error – stop
    error “ERROR:$2: $RESULT” # Send to error func
    exit 0
    fi
    fi
    }

    trap goodbye 1 2 3 15

    ## functions

    onvfat() {
    # First choose a partition for the mcnlive.loop
    PARTNAME=$(df -h –type=vfat |
    $DIALOG –list –title=”$TITLE” –width=400 –height=300 –text=”Select a partition to create the loopfs file on.” –column=”Available partitions:” |
    cut -b1-9)

    if [ ! -e "$PARTNAME" ]; then
    $DIALOG –title=”$TITLE” –error –text=”Something went wrong. Device $PARTNAME does not exist.”
    exit 0
    fi

    echo “$PARTNAME”

    # Ask user size of the image

    FreeSpace=$(df $PARTNAME -B 1048576 | grep -v Available | awk ‘{print $4}’)
    echo “$FreeSpace”
    if [ $FreeSpace -lt 50 ]; then
    $DIALOG –title=”$TITLE” –error –text=”Not enough space on device $PARTNAME”
    exit 0
    elif [ $FreeSpace -gt 2000 ]; then
    MAX=2000
    else
    MAX=$FreeSpace
    fi

    FILESIZE=$($DIALOG –title=”$TITLE” –scale –text=”How much space would you like to use for the loopfs file (in MB)” –min-value=50 –max-value=$MAX –value=50 –step=50)

    if [ "$?" == "1" ]; then
    $DIALOG –title=”$TITLE” –error –text=”You chose not to continue …”
    exit 0
    fi

    # Create the file
    (
    ## Remount the partition
    cmd “umount -dlf $PARTNAME” 2>/dev/null
    cmd “mkdir -p /mnt/mkloop”
    cmd “mount $PARTNAME /mnt/mkloop”

    cmd “dd if=/dev/zero of=/mnt/mkloop/mcnlive.loop bs=1M count=$FILESIZE”

    # Create the filesystem
    mke2fs -q /mnt/mkloop/mcnlive.loop </dev/null 2>&1
    y
    EOF

    cmd “tune2fs -c0 -i0 /mnt/mkloop/mcnlive.loop”
    cmd “umount /mnt/mkloop”
    sleep 3

    ) | $DIALOG –progress –percentage=0 –title=”$TITLE” –text=”Creating the loop file …
    When the OK button is active again, wait two seconds and click on it.”

    if [ "$?" == "1" ]; then
    $DIALOG –title=”$TITLE” –error –text=”You chose not to continue …”
    exit 0
    fi

    }

    onext3() {
    # First choose a partition for mcnlive.loop
    PARTNAME=$(df -h –type=ext3 –type=ext2 |
    $DIALOG –list –title=”$TITLE” –width=400 –height=300 –text=”Select a partition to create the loopfs file on. ” –column=”Available partitions:” |
    cut -b1-9)

    if [ ! -e "$PARTNAME" ]; then
    $DIALOG –title=”$TITLE” –error –text=”Something went wrong. Device $PARTNAME does not exist.”
    exit 0
    fi

    echo “$PARTNAME”

    # Ask user size of the image
    FreeSpace=$(df $PARTNAME -B 1048576 | grep -v Available | awk ‘{print $4}’)
    echo “$FreeSpace”
    if [ $FreeSpace -lt 50 ]; then
    $DIALOG –title=”$TITLE” –error –text=”Not enough space on device $PARTNAME”
    exit 0
    elif [ $FreeSpace -gt 2000 ]; then
    MAX=2000
    else
    MAX=$FreeSpace
    fi

    FILESIZE=$($DIALOG –title=”$TITLE” –scale –text=”How much space would you like to use for the loopfs file (in MB)?” –min-value=50 –max-value=$MAX –value=50 –step=50)

    if [ "$?" == "1" ]; then
    $DIALOG –title=”$TITLE” –error –text=”You chose not to continue …”
    exit 0
    fi

    ## We need a label.
    cmd “umount -dlf $PARTNAME” 2>/dev/null
    cmd “tune2fs -L MCNLIVE $PARTNAME” 2>/dev/null

    ## Remount the partition
    cmd “mkdir -p /mnt/mkloop”
    cmd “mount $PARTNAME /mnt/mkloop”

    # Create the file
    (
    cmd “dd if=/dev/zero of=/mnt/mkloop/mcnlive.loop bs=1M count=$FILESIZE”

    # Create the filesystem
    mke2fs -q /mnt/mkloop/mcnlive.loop </dev/null 2>&1
    y
    EOF

    cmd “tune2fs -c0 -i0 /mnt/mkloop/mcnlive.loop”
    cmd “umount /mnt/mkloop”
    sleep 3

    ) | $DIALOG –progress –percentage=0 –title=”$TITLE” –text=”Creating the loop file …
    When the OK button is active again, wait some seconds and click on it.”

    if [ "$?" == "1" ]; then
    $DIALOG –title=”$TITLE” –error –text=”You chose not to continue …”
    exit 0
    fi

    }

    ##### Main script #####
    # Info and basic decision

    echo “Starting Create mcnlive.loop ”
    echo “Dialog = $DIALOG”

    CHOICE=”"
    ACTION1=”FALSE On_VFAT”
    ACTION2=”TRUE On_EXT3″
    while [ "$CHOICE" = "" ];
    do
    $DIALOG –list –radiolist –title=”$TITLE” –text=”
    This wizard helps you to create a mcnlive.loop image on a chosen device
    in order to work with persistent system wide changes.
    * Don’t start with the bootcode ‘livecd persist’ to run this wizard.
    * You can create an image on a usb stick, an internal or external hard disk.
    * You can use an ext3 filesystem. A Windows VFAT partition only works on a Live USB system
    and only IF the loop file is on the same partition as the base system.
    * If you wish to use an external hard disk or USB stick, make sure it is mounted.
    Icon ‘Devices’ on the desktop. Open the device.
    * This wizard does not create or format partitions. Use the MCC for this task.

    Make your choice and press ‘OK’ to continue.” –column=”Select: ” –column=”Make your choice: ” $ACTION2 $ACTION1 1>”$TMP”
    if [ "$?" == "1" ]; then
    $DIALOG –info –text=”You chose not to continue …” –title=”$TITLE”
    exit 0
    fi
    CHOICE=”$(<$TMP)”
    done

    echo “$CHOICE”

    # sanity check – if user is too dumb to read
    if [ -d "/initrd/changes" ]; then
    $DIALOG –title=”$TITLE” –error –text “Start the live system without the bootcode ‘livecd persist’!”
    exit 0
    fi

    if [ "$CHOICE" == On_VFAT ]; then
    onvfat “”
    elif [ "$CHOICE" == On_EXT3 ]; then
    onext3 “”
    fi

    ## Finished ##
    $DIALOG –info –title=”$TITLE” –text=”mcnlive.loop successfully created.
    You need to restart the Live CD – Live USB with the bootcode ‘livecd persist’.
    Only the changes for this *next* session will be kept.”

    exit 0

    Comment by Antonio — 21 November 2008 @ 11:24

  73. [...] Mandriva很早就有这现象:用UNetbootin把Mandriva One”装”到U盘后,是无法从U盘启动的。省钱并且很懒的人是不会去刻CD的,所以,就要想办法解决。好在有一位高人为我们提供了很好的例子,我们可以如下解决: [...]

    Pingback by Mandriva的LiveUSB相关问题 | insraq.CUHK — 25 November 2008 @ 10:49

  74. thanks… solved a frustrating problem for me!

    al good now.

    Comment by phil — 4 December 2008 @ 5:01

  75. Bien vu.

    Maintenant, ce serait pas mal de pouvoir faire une clé USB persistante (squashfs + unionfs) et à jour avec les derniers updates voire les plf, grâce aux scripts de Draklive:

    - http://mandrivafr.org/trac/magnum/wiki/UtiliserDraklive
    - http://forum.mandriva.com/viewtopic.php?t=96113&sid=26bea2a3d53a41a027ef6e78d97b7ec6

    Comment by Sagittarius — 24 December 2008 @ 13:37

  76. [...] Una volta in possesso della iso è necessario trasferirla su chiavetta USB oppure su un modulo di memoria SD. Vi siete accorti vero che nessun netbook ha il lettore di CD ? Questa operazione non è banale e necessita di un minimo di esperienza e di conoscenza dei comandi della shell. Per fortuna il caro lordik ci è venuto in aiuto, scrivendo questo tutorial: http://lordikc.free.fr/wordpress/?page_id=158 [...]

    Pingback by gianlucavivenzi.com » Blog Archive » Come installare Mandriva 2009 sull’ Asus eee 1000H (e tutti gli altri netbook) — 11 January 2009 @ 16:36

  77. hi!
    i made a live usb with mandriva 2009 iso..
    when “MANDRIVA” screen is loading it stoped the first time and i get a screen with the following:

    uniform multi-platform E-IDE driver
    init started : busybox v1.6.1 (2008-05-16 12:38:44 UTC) multi-call binary
    cannot run ‘/etc/init.d/rcS’: no such file or directory

    then it says to press enter to activate the console

    and it says:
    init started : busybox v1.6.1 (2008-05-16 12:38:44 UTC)self shell (ash) SOMETHING LIKE THAT

    im trying to install from windows on an acer aspire one

    Comment by ALEX — 23 January 2009 @ 1:30

  78. @ALEX
    Usually this kind of problem is due to a bad key preparation. Please check the key preparation phase and especially the key label must be set to MANDRIVAONE.

    Comment by lordikc — 23 January 2009 @ 20:09

  79. [...] Mandriva 2009.1 beta is out. Fortunately I found some time to create the kit for installation onto a USB Key. [...]

    Pingback by Mandriva 2009.1 Beta « Blog L’Ordikc — 13 February 2009 @ 14:53

  80. Hi is it possible to have mandriva kit 2009 . 1 beta on another server? cause I dont know why but I am not able to dwnld . It takes some hours…. and then stops. Maybe rapidshare or mu…. Thank you

    Comment by Pgil — 18 February 2009 @ 16:29

  81. MAYBE I FOUND THE PROBLEM.
    Hey guys… i followed this guide and I had the same problem of “missing operating system”. After many trials I understood that the only difference between my procedure and the lordic procedure was the version of the HP disk format tool. The last version is the 2.18 but this does not work. I luckly found the version 2.06 (at http://download.chip.eu/it/USB-Disk-Storage-Format-Tool-2.0.6_1760368.html) and now everything is ok.

    Comment by Francesco — 20 February 2009 @ 8:24

  82. Thanks Francesco

    Comment by lordikc — 20 February 2009 @ 19:39

  83. “Mandriva 2009.1 beta is out. Fortunately I found some time to create the kit for installation onto a USB Key. [...]”

    Wonderful, works like a charm (but I did not use the hp format tool (instead: I did “sudo install-mbr /dev/sdc” to make the usb disk bootable! (So you guys with a missing operating system..this might help) and I used the partition editor in ubuntu to format the usb-drive to fat32
    Wireless is working out of the box, sound is working, but (still) no recording, with skype no videodevices are found, is there a solution?

    I have an Eeepc 900.

    Thanks for sharing your work!!

    Comment by ab — 27 February 2009 @ 21:04

  84. Firstly thanks for lordikc’s efforts to help us to make the live usb mdv successfully. I also got a problem,I tried to install the Chinese Character version(mandriva-linux-one-2009-KDE4-jp-zh-cdrom-i586.iso) on a usb flash key and i got the fail message “Cannot run ‘/etc/init.rd/rcS’: no such file or directory”.After overwritten by your .usb file ,it works well while the version changed. I can not find the Chinese option any longer. I wonder can you tell me how to modify the .usb file to make the Chinese version back. thanks in advance!

    Comment by sean — 15 March 2009 @ 14:28

  85. Can you please provide the kit for Mandriva 2009.1 RC1 ?

    I tried with your kit for 2009.1 beta but the kernel version is different so although it boot to text mode the modules are not loaded.

    THANKS A LOT

    Comment by Amitabh — 16 March 2009 @ 8:35

  86. THANKS a lot for 2009.RC1.
    Had been trying to open your initrd.usb for 2009.1beta but it kept giving me ‘Malformed Number’ error. Don’t know why.
    Was using gzip -dc initrd.usb |cpio -id to open it.

    Comment by Amitabh — 17 March 2009 @ 16:07

  87. [...] Por L’Ordikc en Ingles o Por Marco Antonio Gomez En Portugues o Español Traducido por Mandriveros.com. [...]

    Pingback by Mandriva ONE 2009.1RC1 en una memoria USB. « Mandriva Linux… Sonora — 1 April 2009 @ 17:30

  88. Can you please provide the kit for Mandriva 2009.1 RC2 ?
    THANKS IN ADVANCE

    Comment by Amitabh — 9 April 2009 @ 18:10

  89. Can you please provide the kit for 2009.1 RC2 ?
    Thanks in advance.

    Comment by Amitabh — 10 April 2009 @ 7:44

  90. I’ll try if I find some time to do it.

    Comment by lordikc — 10 April 2009 @ 18:30

  91. Dear L’Ordikc,

    Thanks a lot for your handy kits, because without them it’d be almost impossible to install Mandriva through USB (one day we should file them a bug to resolve this). If it would be quite burdensome for you to create the kits every time there is a new release, could you teach us how to build the kit by oneself, so that more people could share the tasks? I don’t know which way takes more efforts for you though.

    Comment by RobertoMS — 28 April 2009 @ 11:34

  92. [...] duro donde lo instalé, por lo que era más factible usar unetbootin. La guía que seguí está en esta URL (en inglés), que funciona [...]

    Pingback by 42 Blocks :: Mandriva One en el Aspire One :: December :: 2008 — 29 April 2009 @ 21:27

  93. Kit of 2009.1 Final! So fast! Thank you a lot!

    Comment by RobertoMS — 1 May 2009 @ 8:48

  94. Worked fine first time, created 2009.1 stick on 2009.1, has syslinux 3.75.

    Profuse thanks!

    Someone mentioned MCNLive.. I STILL use the Toronto (2007.1) release as a toolkit, shame Mandriva couldn’t do something like that.

    Comment by Greg McGee — 12 May 2009 @ 15:15

  95. Hi,

    I’m using Windows XP. I followed the instructions. First i formatted the usb flash with the tool and the label is as it is said MANDRIVAONE.

    I downloaded the iso of the final release. 2009.1 and copied the folder “loopbacks” into the usb root directory. (USB\loopbacks\)

    I downloaded the necessary key tools. (the final new release) I extracted it and the file I had was kit_mdv2009. I copied this file into the root directory. “This file contains a initrd.usb, syslinux.cfg and /boot/vmlinuz file.” I don’t know what this means. There was only one file in the corresponding file I downloaded and it was kit_mdv2009. Maybe these files are in this file but I can’t extract them. I don’t know if I need it to do or not.)

    And finally I downloaded syslinux and made the usb flash memory bootable.

    When I boot from USB I get this error:
    SYSTEMLINUX 3.82 Debian EBIOS Copyright (C) 1994-2007 N. Peter Anvin
    Could not find kernel image: linux

    Do you have a solution?

    Comment by Kaan — 25 July 2009 @ 12:42

  96. Hey there,
    reason I ended up here is because I heard Mandriva was able to revert to the windows bootloader. I had been “playing” with different distributions on my aspire one and when I wanted to go back to winxp, I was stuck with grub and couldn’t get rid of it.
    Since the aspire one doesn’t have an optical drive, my only option is usb. MCNLive doesn’t have the option to remove GRUB, spent the last couple days figuring this one out.
    All in all, the reason why I can’t just format the drive is because it contains the D2D recovery partition which I basically need to salvage to be able to restore my aspire one to factory defaults… and partition managers aren’t working… I figured I could wipe the main partition and just run D2D. but then every time I start my one, i get a “Virus!” message, like the bootsector’s been rewritten bad.

    I know it’s off topic but at the same time maybe there’s a way to fix the MBR from Mandriva which I’m not aware of.

    Thanks for posting this article, great read!

    Fredo

    Comment by Fredo — 11 October 2009 @ 9:42

  97. excellent it works!!! mandriva 2010 is out too, i think u guys should work on that too :-) . keep it up

    Comment by dave — 5 November 2009 @ 5:10

  98. Bonjour,

    Est-ce qu’il y a un kit pour Mandriva 2010.
    Est-ce possible d’utiliser le kit 2009 pour
    obtenir un USB demarrable.

    Merci d’avance

    Comment by Karym Metwally — 6 November 2009 @ 7:12

  99. La version 2009 ne fonctionnera pas. Je vais fournir le kit 2010 ce WE.

    Comment by lordikc — 6 November 2009 @ 7:24

  100. excellent!!! you guys already have the 2010!!!!!

    Comment by dave — 7 November 2009 @ 19:25

  101. [...] http://lordikc.free.fr/wordpress/?page_id=158 [...]

    Pingback by l’etincelle » Archive du blog » Mandriva 2010 ONE USB avec persistence — 24 November 2009 @ 19:37

RSS feed for comments on this post. TrackBack URL

Leave a comment

Powered by WordPress