Moving directories after installed

Bill Williamson batkiwi at
Wed Mar 20 09:57:07 PST 2002

I've got my LFS system working!  However, i need to make some changes:

Currently I've got hdA, a 20gig hd that has my old slackware system, with my
old stuff on it, and hdB, my 4gig hd with LFS on it.

I've got lilo on hdA obviously, with 2 entries, slackware and LFS.

I can tar and back up to my windows system everything I need to keep on the
20gigger, so the temp storage is no problem.

Here's what I need to do:
1. The really tough part (for me): get lilo on hdB, then physically swap it
over to be hdA.  I'm guessing i'll need to fudge something with the config
when I run lilo, but I'm not sure what.  I know to switch it to hdA i simply
make it primary master, but not how to trick lilo into thinking hdb will be
hda once I reboot.

2. The easy part: format the 20gig.  Currently it's 17gigs ex2, 3 gigs swap.
I've got my 4 gig for 3 gigs ext3, and 1 gig swap, so I want to use the
entire 20gig for storage.  I can find this on my own, thought i'd mention it
with the rest though if someone wants to be nice :P

3. The sorta tough part that I MAYBE have figured out:  After 1 and 2, i'll
hdA: 4 gig drive with LFS and swap on it
hdB: 20gig empty drive

What I want to end up with:
hdA: 4gig drive with "system" on it and swap
hdB: 5gig /usr, 15gig /home

So basicly how do I move everything from /usr and /home to the new drive?
My best guess:
1. go into runlevel1
2. fdisk new disk into 5 and 15
3. format with e2tools or something
4. mount under /newusr and /newhome
5. cp -r /usr /newusr
6. cp -r /home /newhome
7. mv /usr /oldusr
8. mv /home /oldhome
9. mount 5 as /usr, 15 as /home
10. set up /etc/fstab for new /usr and /home
11. reboot
12. tar /oldhome and /oldusr just in case, then rm -rf /oldhome /oldusr if
the system comes up

Am I missing anything?  Will I totally kill my system due to me making a bad

Thanks guys!


Unsubscribe: send email to listar at
and put 'unsubscribe lfs-support' in the subject header of the message

More information about the lfs-support mailing list