[Cialug] Moving Linux from one disk to another

Josh More morej at alliancetechnologies.net
Thu Sep 4 16:11:20 CDT 2008


I've used tar and grub-install to do such things in the past.  I've used
dd.  They're all about the same.

However, these days, I'd just build a new server and migrate the apps
and data to the new code.  It's hard enough to keep legacy stuff
running, much less when you keep moving the same logical server from box
to box.  Of course, I also recommend putting everything in LVM, so you
don't have to worry about piddly things like disk space.  :)

If you decide to use dd solution, the idea would be:

1) Image the data
2) Boot your target system (Knoppix, Helix, System Rescue, etc)
3) Move the image somewhere (CD, USB drive, etc)
4) Unroll the image onto the disk using dd
5) Use fdisk to adjust the size of the partition (may require a reboot
to load the new table)
6) Run an fsck on the unmounted file system.  Really, run the check.  If
it's ext, run with -f.
7) Resize the file system (resize2fs, resize_reiserfs, etc)
8) Cross your fingers and reboot.



-Josh More, RHCE, CISSP, NCLP, GIAC 
 morej at alliancetechnologies.net 
 515-245-7701

>>> "Nathan C. Smith" <nathan.smith at ipmvs.com> 09/04/08 3:47 PM >>>

What are some good ways to move linux from one disk to another?  I have
a running installation on a 20 GB disk I'd like to move to something a
little bigger and then take advantage of the new space.  Is that
something I could do with DD and then use another program to expand my
filesystems into the available space?  What would I use to expand the
filesystem and is it available from the command line or by using
knoppix, etc.?

Is there anything quick and easy?  I may give ghost a try but I thought
I would ask the question.

Looking for tips pointers and valuable life experience.  TIA.

-Nate
_______________________________________________
Cialug mailing list
Cialug at cialug.org
http://cialug.org/mailman/listinfo/cialug



More information about the Cialug mailing list