topic title: live persistence
anticapitalista
Posts: 5,955
Site Admin
Joined: 11 Sep 2007
#1
Running antiX live with persistence on a usb device.

1. Install antiX to usb device using unetbootin or new_usb.sh(recommended)
2. You can set up persistence files before using the stick. Advantage is that persistence is ready from first boot. (see later)

Setting up persistence while running live usb stick.

1. Boot using the first option shown in boot menu.
2. Open RemasterCC app from Menu-> Applications->Others - give root password (for live this is root)
3. Click on Set up live file system.
4. You need to set up rootfs to save changes made to system ie adding/removing applications.
5. You need to set up homefs to save changes made to home user ie documents, themes, wallpaper.
6. To set up homefs (rootfs is exactly the same)

Using Set up live application :-
Directory - navigate to Other -> live-> boot-dev-> antiX
Size -Depends on what you want to store. If you intend to save a lot of large files in your home directrory, eg avi video files that you want to watch on successive boots, make homefs gib. make sure you have space on your stick.
Same applies for installing apps for rootfs.
This is what I suggest for a 4GB stick running antiX-base. YMMV.
homefs=200MB rootfs=500MB
Leave ext blank for now.
format. Choice between ext2 or ext3. ext2 is reommended.
Set up homefs , click ok and repeat for rootfs.
A popup should show messages of success (or failure).

The persistence files are now set up.

Reboot and choose correct persistence option in boot menu. home is only for home, whereas root is for both home and root.

On first live boot, you will be prompted to change root and user passwords (not user name -it is still demo) for extra security.
At desktop you will be asked to set up root persistence. There are 3 choices. semi-automatic is recommended.
Make the changes you want eg change wallpaper for homefs changes, install an app for rootfs.

Click exit/reboot from antiX menu and a popup will indicate tha persistence changes for are being saved. (homefs changes are automatically saved)
On next reboot (still using the same persistent option), there will be a slight delay when booting.

New desktop should have all your changes.

Adding a new kernel. At the moment only antiX kernels will work with persistence and a bit of fiddling is required.

Run antiX live with persistence (rootfs), install latest antiX-kernel and headers (if needed).
To be safe, run update-initramfs -u -t -k all

Copy the new vmlinuz-3.2.2-antix2 file from boot to /live/boot-dev/antiX and rename vmlinuz1
Edit menu.lst in /live/boot-dev/boot/grub to include: (note: vmlinuz1 entry)

Code: Select all

## ISO boot
title antiX-M11-base-686 (Root Persistence-new kernel)
kernel /antiX/vmlinuz1 quiet lean noxorg blab=antiXlive vga=791 bdir=antiX persist
initrd /antiX/initrd.gz
Reboot, using Root Persistence-new kernel option.

If all works ok, then you could remove the old kernel and headers and rename vmlinuz1 to vmlinuz and delete the new menu entry mentioned above. Make sure you recreate the sym links in boot to link to new vmlinuz and initrd.img.

Remastering.

Once you are satisfied that all is working as it should, you may want to remaster your changes. Basically this creates a new linuxfs file (in effect a sort of new iso) that you boot from. Then you can delete all the old rootfs/homefs files (if you do not need them).

An example.

I have antiX-base-test1 installed using new_usb.sh to a 2GB partition, ext2 format of a 4Gb stick. The other 2GB partition is formatted as fat32 for data.
rootfs is 400MB and homefs 200Mb.
I installed latest kernel as described above as well as abiword. On reboot all seem to work ok. Time to remaster.

Open RemasterCC app from Menu-> Applications->Others - give new root password.

Click on Remaster and follow the instructions. The reastering will take time depending on your CPU and RAM.

Once finished, click on Set up live file system and set up a new rootfs in /live/boot-dev/antiX but this time in the ext field add the word .new (you must include the dot).

Click ok and reboot into your new antiX!

You can remove the old rootfs and linuxfs in /live/boot-dev/antiX to save space.

Added: Can I have 2 partitions on my stick and run persistence?

You may decide that you do not want to use all of your usb stick to run antiX live persistence, for example you have an 8GB stick, want to use antiX-base plus add a few apps like abiword, gnumeric and you want to have a data partition for files that both linux and windoze will see (fat32 for example).

It is possible to do this, though it needs a bit of fiddling. This is what I did.

1. Install latest antiX-base-test1 (or full if you prefer) to your usb stick using new_usb.sh. This will take over all the disk.
2. Once finished, save a copy of the contents somewhere, just in case.
3. Use gparted to shrink your usb partition and set up the space to whatever you want eg fat32 and give it a label eg mydata
4. Once finished, remove and re-insert your usb stick and check that you do in fact have 2 'folders' one contaning your live antiX. ie all the stuff you saved in 2.
5. You should be able to boot your stick and set up persistence and use your data partition as well. Though I have no idea if windoze will see your data partition.
Posts: 279
afab4
Joined: 17 Oct 2009
#2
Works great. i am posting from my new USB stick with the new kernel installed. Wireless works fine.
I can't seem to make iceWM with no icons stick though. It wants to always install the desktop with icons and my conky is located where the icons are.
anticapitalista
Posts: 5,955
Site Admin
Joined: 11 Sep 2007
#3
Use boot cheat noRox

If that doesn't work (it will be a bug), boot using homefs (or rootfs) and manually edit ~/.icewm/startup file to edit out the rox-pinboard option, and the ~/.xinitrc default to edit out rox-pinboard ie to read as icewm option as shown in .xinitrc.
Posts: 279
afab4
Joined: 17 Oct 2009
#4
anticapitalista wrote:Use boot cheat noRox

If that doesn't work (it will be a bug), boot using homefs (or rootfs) and manually edit ~/.icewm/startup file to edit out the rox-pinboard option, and the ~/.xinitrc default to edit out rox-pinboard ie to read as icewm option as shown in .xinitrc.

I ended up modifying .xinitrc so it defaults to icewm.
works fine now.

Installed mail client icedove and am modifying my toolbar next.
Then on to the remaster __{{emoticon}}__

AND....The remaster worked exactly as you posted.
Still couldn't save my noRox iceWM desktop though. No biggie I just edited .xinitrc again.
Booted the same thumb drive on my other laptop with b43 card. Still need to modprobe b43 to get ceni to see the interface.
How cool is this!
anticapitalista
Posts: 5,955
Site Admin
Joined: 11 Sep 2007
#5
afab4 wrote: How cool is this!
Very cool, eh! Enjoy!

BTW any idea as to why ceni won't 'remember' the settings? Does wicd do it?
anticapitalista
Posts: 5,955
Site Admin
Joined: 11 Sep 2007
#6
Just to add that you can run antiX-live with persistence in this way as a frugal install on a hard drive. This has some advantages over a full install, the main one being that it takes up less space. Its quite a fun way to run. A bit like how Puppy linux works.

Another thing is that you can run using the toram cheat as well. If your RAM is around 1GB, booting may be slower, but you may find that once at desktop, apps open faster. If you have plenty of RAM, then running toram may not be that beneficial.
Posts: 279
afab4
Joined: 17 Oct 2009
#7
anticapitalista wrote: BTW any idea as to why ceni won't 'remember' the settings? Does wicd do it?
No difference with wicd.
The interface will not show up until I run modprobe b43 from root terminal.
Immediately after I run the modprobe, wireless connects automatically with ceni, so ceni is saving data.
Maybe if I add b43 to /etc/modules ??
anticapitalista
Posts: 5,955
Site Admin
Joined: 11 Sep 2007
#8
Is the lean/Xtralean cheat being used? Try without it.

You could also try adding the modprobe b43 line to /etc/rc.local
Posts: 279
afab4
Joined: 17 Oct 2009
#9
anticapitalista wrote:Is the lean/Xtralean cheat being used? Try without it.

You could also try adding the modprobe b43 line to /etc/rc.local
Taking the lean cheatcode out made no difference.
Adding the modprobe b43 to /etc/rc.local was successful. __{{emoticon}}__
Posts: 279
afab4
Joined: 17 Oct 2009
#10
anticapitalista wrote:Running antiX live with persistence on a usb device.



Remastering.

Once you are satisfied that all is working as it should, you may want to remaster your changes. Basically this creates a new linuxfs file (in effect a sort of new iso) that you boot from. Then you can delete all the old rootfs/homefs files (if you do not need them).

An example.

I have antiX-base-test1 installed using new_usb.sh to a 2GB partition, ext2 format of a 4Gb stick. The other 2GB partition is formatted as fat32 for data.
rootfs is 400MB and homefs 200Mb.
I installed latest kernel as described above as well as abiword. On reboot all seem to work ok. Time to remaster.

Open RemasterCC app from Menu-> Applications->Others - give new root password.

Click on Remaster and follow the instructions. The reastering will take time depending on your CPU and RAM.

Once finished, click on Set up live file system and set up a new rootfs in /live/boot-dev/antiX but this time in the ext field add the word .new (you must include the dot).

Click ok and reboot into your new antiX!

You can remove the old rootfs and linuxfs in /live/boot-dev/antiX to save space.
I have made another USB using the upgraded and improved version(s). While it is quite different to use versus the older version, I was able to muddle through successfully and now have a remastered 8GB thumb that mirrors my hard drive install. I was even able to use the resize rootfs to increase my partition from 1.5GB to 2GB.
Also very cool the way rootfs.new and rootfs.old are created automatically.
Some questions:
1. Is there a way to use the new remastered USB to install antiX to a hard drive? If not then what is now recommended for those who do not have a CD/DVD reader on their box and only have USB ports? ( I tried this but no grub will install.)
2. What is the purpose of the antiXusb app in the antixcc? Is this still functional? Does the new_usb.sh not replace this?

EDIT:
I tried installing my remastered USB to my hard drive and the installation was successful and grub installed to the MBR ok but when I got to the login screen it showed"demo"as login and no matter what i put in as a password="demo","my_password","root_password" and combinations of those, I got no further.
I tried both ways as gui and cli-installer and no difference. Tried installing from"Live USB" and"Root Persistance" boot options and no difference.
Finally got my DVD remaster and installed it via cli-installer with no problems. The DVD install asks for a new hostname, user name/password, root name/password etc. but the USB install doesn't do this and also doesn't seem to save the names/passwords from the remastered USB.

EDIT UPDATE:
I decided to use new_usb.sh to make a bootable thumb drive using the original antiX-test2.iso. i then used the newly made thumb drive to install via cli-installer to my hard drive. This installed flawlessly so i guess somehow I borked something up while remastering and it in turn borks my remastered install.
Posts: 6
wh7qq
Joined: 07 May 2012
#11
I set up antiX-base-t3 on a 4G usb stick using new_usb.sh with a single ext2 partition for the entire stick. Worked great but wanted to update so after rebooting, did an apt-get update && apt-get dist-upgrade. Worked great again after increasing the rootfs size to 1G. After some use, did"dpkg -i" for the 3.3.5 kernel".deb" files and copied the result per the first post in this thread. Renamed it to vmlinuz1 per instructions. When I tried to edit
menu.lst in /live/boot-dev/boot/grub to include: (note: vmlinuz1 entry)
I found that there was no grub directory in /live/boot-dev/boot/.

Code: Select all

ls -l /live/boot-dev/boot/
total 124
dr-xr-xr-x 2 root root   4096 May 16 15:41 extlinux
-r-xr-xr-x 1 root root 116508 May 16 15:41 memtest
So I am still booting into the 3.3.3 kernel, which works ok (but no suspend). I found"menu.lst" files in the following locations:

Code: Select all

 find / -name menu.lst
/usr/lib/antixsnapshot/new-iso/boot/grub/menu.lst
/live/aufs/usr/lib/antixsnapshot/new-iso/boot/grub/menu.lst
/live/aufs-ram/usr/lib/antixsnapshot/new-iso/boot/grub/menu.lst
/live/linux/usr/lib/antixsnapshot/new-iso/boot/grub/menu.lst
Which should I edit? Did I miss a step?

Thanks in advance,

Paul
Posts: 279
afab4
Joined: 17 Oct 2009
#12
[/quote] I found that there was no grub directory in /live/boot-dev/boot/
[/quote]

I was puzzled by your encounter so I tried to emulate your steps.
1. I booted the live CD made from antiX-base-t3.iso
2. Used new_usb.sh to make a new bootable USB.
3. Installed the persistence options.
4. Booted using root persistence.
5. Installed the 3.3.5 kernel using dpkg -i
6. Followed the instructions anti gave to copy the new vmlinuz-3.3.5-antix.1.486.smp file from boot to /live/boot-dev/antiX and rename to vmlinuz1. Modified the menu.lst in /live/boot-dev/grub/menu.lst
7. Did an apt-get update and apt-get upgrade.
8. Saved everything to persistence when prompted upon reboot.

Didn't have any issues and the new kernel is booting OK.
I think you might just try to make a new /live/boot-dev/grub/menu.lst using the menu.lst that anti included in his post.
I will say that I did not have to include the blab=antiXlive in my menu.lst which reads:

Code: Select all

Code:
## ISO boot
title antiX-M11-base-686 (Root Persistence-new kernel)
kernel /antiX/vmlinuz1 quiet lean noxorg vga=791 bdir=antiX persist
initrd /antiX/initrd.gz
i can't figure why your USB would boot off any of the menu.lst files you posted. __{{emoticon}}__
Next step for me is to remaster the USB.
EDIT:
Remastered. Saved homefs. Set up a new rootfs. Deleted vmlinuz. Renamed vmlinuz1 to vmlinuz and changed my menu.lst accordingly. Deleted the old rootfs etc.
Everything seems OK. Posting from USB with persistence.
Posts: 6
wh7qq
Joined: 07 May 2012
#13
Arrrgh! Finally after much thrashing, found my omision: Failed to rename vmlinuz1! I knew I'd missed something. Being old and dumb is a bxtch! Now it is running the 3.3.5 kernel. Thanks for the suggestions and effort.

Paul