-
persistent home: can I resize the loopback file knoppix.img?
Hi, I'm a linux and knoppix newby. I recently created a persistent home directory by formatting a 2GB knoppix.img loopback file in a 40GB LaCie portable external drive (FAT32). I believe, however, that I may need a bigger loopback file in the future. Is it possible to resize the persistent home file from Knoppix?
If this is not possible, would it be possible to move the /home contents to another directory in the drive, erase knoppix.img, create a bigger loopback file, and then replant the previous /home contents in the new /home without losing any data?
-
Senior Member
registered user
Re: persistent home: can I resize the loopback file knoppix.
--2GB is the maximum single-filesize for Fat32. Your second scenario is definitely possible on any linux-native filesystem, such as Reiserfs or ext(2/3); use ' cd sourcedir; cp -apRv . destination-dir ' is what I'd recommend, or tar, or even ' mc '.
--You could also "stack" more 2GB loopback files on top of /home, like so:
' mkdir /home/you/extraspace '
' touch /home/you/extraspace/NOTHERE ' == If you LS the dir and see NOTHERE, ya know it's not mounted.
' dd if=/dev/zero of=/mnt/fat32drive/mnt-home-extraspace-2gb.img bs=1M count=2047 ' == Make the bigfile
' mkreiserfs /mnt/fat32drive/mnt-home-extraspace-2gb.img ' == Answer Y (Format it)
' mount /mnt/fat32drive/mnt-home-extraspace-2gb.img /home/you/extraspace -oloop,noatime,rw ' == Also you can use 'notail' as a mount option if you prefer speed over maximum storage space.
(I'm rather tired ATM; lemme know if you need more hints.)

Originally Posted by
amador
Hi, I'm a linux and knoppix newby. I recently created a persistent home directory by formatting a 2GB knoppix.img loopback file in a 40GB LaCie portable external drive (FAT32). I believe, however, that I may need a bigger loopback file in the future. Is it possible to resize the persistent home file from Knoppix?
If this is not possible, would it be possible to move the /home contents to another directory in the drive, erase knoppix.img, create a bigger loopback file, and then replant the previous /home contents in the new /home without losing any data?
-
Senior Member
registered user
" image, as far as it looks it is just a directory.
just a space is missing from your lines Dave.
Code:
mount /mnt/fat32drive/mnt-home-extraspace-2gb.img /home/you/extraspace -o loop,noatime,rw
by a space I mean that the space between -o and loop (in my line), if the space is not there it might (read should) not work
EDIT the MAX filesize is actually 4G minus one byte, but for some reason knoppix wont alow that.
moving home is not that hard.
just make another imagefile copy everything there and replace the entries in /etc/fstab so that your new file is listed instead,
you can certainly add another file and make that a subdirectory of your old one. i have that.
/home/user is one the original one
and home/user/extra is the "extra
then you can make a /home/user/extra2 and3...or a /home/user/extra/extra...
it is the textfile /etc/fstab that tells linux where the disks/partitions/images are to be mounted. man fstab might help you some more (and asking here aswell)./EDIT
-
Senior Member
registered user
Re: " image, as far as it looks it is just a directory.
--Try it w/o the space. I do it all the time, it works.
I've run into the 2GB max filesize limit more times than I can count ('zip' is famous for this) and finally just stopped using Fat32 for storage outside of native Windoze.
--Original poster, I'd highly recommend resizing the Fat32 partition on your drive, and making about 1/2 of it native Linux - reiserfs, ext3 or whatever. That way *you* get to use the maximum amount of space for whatever you want, including file permissions. I *think* Knoppix should be able to find your persistent home on just about any partition type, but you should experiment.

Originally Posted by
OErjan
just a space is missing from your lines Dave.
Code:
mount /mnt/fat32drive/mnt-home-extraspace-2gb.img /home/you/extraspace -o loop,noatime,rw
by a space I mean that the space between -o and loop (in my line), if the space is not there it might (read should) not work
EDIT the MAX filesize is actually 4G minus one byte, but for some reason knoppix wont alow that.
moving home is not that hard.
just make another imagefile copy everything there and replace the entries in /etc/fstab so that your new file is listed instead,
you can certainly add another file and make that a subdirectory of your old one. i have that.
/home/user is one the original one
and home/user/extra is the "extra
then you can make a /home/user/extra2 and3...or a /home/user/extra/extra...
it is the textfile /etc/fstab that tells linux where the disks/partitions/images are to be mounted. man fstab might help you some more (and asking here aswell)./EDIT
Similar Threads
-
By harys in forum Laptops
Replies: 0
Last Post: 06-08-2007, 07:11 PM
-
By drg55 in forum General Support
Replies: 2
Last Post: 12-30-2003, 01:15 AM
-
By PsycoX in forum General Support
Replies: 4
Last Post: 09-09-2003, 02:23 AM
-
Replies: 0
Last Post: 05-05-2003, 06:50 AM
-
By Phredd in forum Customising & Remastering
Replies: 4
Last Post: 12-22-2002, 02:49 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules

KNOPPIX 9.1 Linux Install & Live DVD 32bit & 64bit
$19.99

Windows XP, Vista, 8.1, Linux Knoppix, Office XP, (6 CDS)
$12.00

KNOPPIX USB DVD OS , BEST OF ALL HIGHLY RECOMENDED
$11.99

Knoppix Live GNU Linux System 9.1 on Bootable CD / DVD / USB Flash Drive
$5.99

Knoppix NSM 1.2
$8.00

VINTAGE SOFTWARE | KNOPPIX STD 0.1 (SECURITY TOOLS DISTRIBUTION)
$7.97

Hamshack Live DVD-ROM
$7.00

Vintage Linux DVD - Knoppix 5.2 - c't Magazine - 7 / 2007 - Software Collection 2
$8.03

Knoppix 5.0.1 ULTRA RARE Linux DVD - Linux Pro Extra August 2006
$34.42