Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

imaging a drive to replace it



On Thu, Mar 12, 2009 at 03:57:31PM -0400, Tim Callaghan wrote:
> Are there products to replace a drive in a Linux box by imaging it to a new
> hard drive?  I've used Acronis True Image plenty of times on my windows
> machines but never had the need (until now) to do it for linux.
> Thanks,

If you can plug them in at the same time, dd is your friend.

dd if=/dev/hda of=/dev/hdb

will get everything from disk /dev/hda and put it on /dev/hdb,
assuming hdb is the same size or larger. 

Or you might create partitions on the new disk and do it one
partition at a time:

dd if=/dev/hda3 of=/dev/hdb2

again, the destination partition must be the same size or
larger.

Or you can create partitions and filesystems and transfer
at the per-file level with "cp -r" or rsync or tar with pipes,
or...

Tell us more about your situation and we can refine this for
you.


-dsr-

-- 
http://tao.merseine.nu/~dsr/eula.html is hereby incorporated by reference.

You can't defend freedom by getting rid of it.






BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org