I created a knoppix.img file by choosing "Create a persistent KNOPPIX home directory" and placing it on /dev/hda1 which has 1.1 GB of free space. Unfortunately, I created it with only 10 MB thinking that's a good size to transfer to a USB stick if needed. I now realize that I need at least 100 MB for a project I'm working on. I don't want to redo the image file, especially since I've put in a fair amount of time customizing it. What to do?


The answer is to resize the image.  Here's how:

 1) boot with Knoppix but don't mount the persistent home directory
 2) mount the partition that holds the image read/write
 3) add on a bunch of zeros to bring it up to the desired size
 4) check it
 5) resize it
 6) reboot

In other words, to add 90 MB to a 10 MB image that is on /dev/hda1:

 boot: knoppix 2
 mount /dev/hda1 /mnt/hda1
 dd if=/dev/zero bs=1M count=90 >> /mnt/hda1/knoppix.img
 e2fsck -pf /mnt/hda1/knoppix.img
 resize2fs /mnt/hda1/knoppix.img
 reboot

When knoppix boots the second time, you can now specify the new image file. For example,

  boot: knoppix home=scan

BTW, the new Knoppix (v3.8.1) stores not only your home folder but also all your system stuff in the image. So if you configured Apache, for example, all your settings are saved in the image.

Regards,
- Robert
http://www.cwelug.org/downloads
Help others get OpenSource software.  Distribute FLOSS
for Windows, Linux, *BSD, and MacOS X with BitTorrent



_______________________________________________
CWE-LUG mailing list
[email protected]
http://www.cwelug.org/
http://www.cwelug.org/archives/
http://www.cwelug.org/mailinglist/

Reply via email to