Mandriva 2010 one USB with persistence

I made a new kit for mandriva one 2010 in which I enabled persistence.

New: It’s now natively in the kit since 2010.1.

Download this file and follow instruction given in this page.

Then, in order to enable persistence, create a file named data at the root of your USB stick this way:

#dd if=/dev/zero of=data bs=1k count=128k
#mke2fs data

Adapt 128k to your needs. The content of this file will not be accessible from Windows so you should keep writing your personnal files on the root of the USB stick i.e. in /live/media.

After the first boot alter the /etc/init.d/halt file this way:

231,233d230
< # Remount /live/media/data ro
< mount -n -o ro,remount /dev/loop1 /live/memory
<

Note you can revert to initial state by recreating a new empty data file.
Beware that some updates might alter the /etc/init.d/halt file.

Enjoy your mandriva one session.

This entry was posted in Mandriva One USB. Bookmark the permalink.

8 Responses to Mandriva 2010 one USB with persistence

  1. vanzetti44 says:

    Good News !
    I tryed it but i am not sur I have understand the phase who we must change the halt file.
    Can we add to the line 231 ?:
    < # Remount /live/media/data ro
    < mount -n -o ro,remount /dev/loop1 /live/memory

    I tryed it, but it’s not ok.

    Can you more explain what to do ?

  2. lordikc says:

    Yes but remove < before.
    You should add these lines after the block remount remaining read-only.

    It should look like this:
    # Remount read only anything that’s left mounted.
    # gprintf “Remounting remaining filesystems readonly\n”
    mount | awk ‘{ print $3 }’ | while read line; do
    fstab-decode mount -n -o ro,remount $line
    done

    # Remount /live/media/data ro
    mount -n -o ro,remount /dev/loop1 /live/memory

    action “Unmounting proc file system: ” umount /proc

  3. Greg McGee says:

    Been using your setup for a few releases, works great on far more hardware than anything else… Any chance at an update to 2010-2?

    Thanks!

  4. lordikc says:

    I haven’t realised there was a 2010.2… I’ll do it in the near futur.

  5. Maarten Provo says:

    Great tutorial! Works fine, but one problem though. When I’m trying to install java, i get an error ’21Mb needed on the filesystem’ (same for every other thing I try to install). I’m guessing its some sort of out of disk-space notice. But I’ve made a 1gb data file and would find it hard to believe that it’s full already.

    Any suggestions

  6. lordikc says:

    Have you check the available space through “df -h” ?
    May be something went wrong during the data file creation. Did you format it with mke2fs ?

  7. Maarten Provo says:

    That was the problem indeed. Didn’t know the regular updates would take so much space!

    I also noticed the computer won’t shut down after editing the halt-file. It stops at: ‘INIT: no more processes left in this runlevel’ but doesn’t turn off

  8. lordikc says:

    Well it should halt indeed. I use this key almost every days and it turns the computer off.