<quote who="Alan Lee">
> I am required to upgrade a clients HDD, under linux. Currently, he has a
> 2gb HDD.. and its about full.. and he now has a 30gb HDD... whats the best
> way to transfer the data from one drive to the other? I saw a command,
> about 6-8 weeks ago, in this list, but I lost a few hundred mails just the
> other week.. dang microsoft!
Well, first off, do you need to get rid of the old drive? :)
Method 1:
Work out which partition is needing the most space (probably /home). Make
a filesystem on the 30gb drive, and mount it as /mnt/home. cp -a /home/*
/mnt/home/, then mount the 30bg drive to /home.
If everything is copied, and it all works okay, you can remove /home from
the original drive, and resize /var or /usr (probably /var, as it's always
nice to have some spare room there, you can usually get away with a tiny
/usr on a server).
Method 2:
If you really want to change the drives, you'll have to use either dd to
copy partitions exactly, or cp -a to copy the contents with all their
properties intact. If you need to do some reorganising of partition sizes,
this is a good opportunity; just cp -a everything across once you have
what you need. You can even change which partitions you have and where.
Note that you'll run into booting problems if you cp -a without running
lilo (boot from a BBC, a spare boot floppy, or a distro cd).
- Jeff
-- [EMAIL PROTECTED] ------------------------------- http://lwn.net/daily/ --
I wonder how many errors have gone unfixed due to misspellings of
"FIXME".
--
SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/
More Info: http://slug.org.au/lists/listinfo/slug