Thanks for the detailed info on using tar. It certainly made me feel better
knowing what was going on. I just created /opt, and pointed fstab to an empty
partition. Then I used your command to move /var. Being paranoid, I just had a
browse through /mnt when I was done and checked to see what was moved. It was
all there. Then I used the same technique to copy /usr. This currently resides
on a 2G partition, an is 1.8G already! I used your command again, and. . .
waited. Then I went down stairs to get a smoke. Had another look, and finished
my smoke. Then I went and made a cup of tea. Enjoyed the tea, and was just about
to go make another one, when it finally finished! I updated fstab, and
re-booted, and . . .
Everything worked perfectly! I love when a plan comes together.
I've now got /usr, /var and /opt on separate partitions. /home, / and my swap
space are still on their original partitions. and I've got a free 2G partition
where /usr used to live.
My next step is to re-arrange my first hard drive. I can use the same trick to
back-up /home to a sub-directory of /var for the moment. I am just concerned
about / and swap.
Is swap initialised in single-user mode? Even if it is, I should be able to just
un-initialise it, right? The most worrying point is messing with /. I do have
two 800M partitions set aside for CD images, so I should be able to copy / to
there, and then burn it to CD. But how do I copy / without including /home,
/var, /usr and /opt? I just want an exact copy of the partition. is there a
command I can use to copy a partition directly, rather than having to work with
the entire file system? That way I could just say copy /dev/hda2 and be done
with it. I think I'll also copy my kernel to floppy, and change the floppy to
boot from CD for the time being. What was the command for changing the root
device?
Thanks again for all your help and understanding. Little by little, this UNIX
stuff is sinking in. I am hoping to get some training courses in UNIX soon, then
I can start helping others and stop bothering everyone on this list.
Cheers,
John Gay
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!