Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Could you please advice how to clone CentOS with all installed software to another box.

What tools should be used?

share|improve this question

migrated from stackoverflow.com Dec 21 '10 at 17:20

This question came from our site for professional and enthusiast programmers.

    
Is the hardware identical, or different? If so, how different is it? –  Zoot Dec 21 '10 at 17:54
    
Which release of CentOS do you want to clone? –  kamae Feb 28 '12 at 8:30
add comment

3 Answers

Couldn't you just clone the hard drive using a dd command and stick it into a new box? Here is more on using dd: https://help.ubuntu.com/community/DriveImaging

share|improve this answer
1  
+1 for not mentioning things like clonezilla or others when dd is perfectly capable! –  g19fanatic Dec 21 '10 at 18:18
add comment

I've used PartImage for things like that.

share|improve this answer
add comment

While dd / ddrescue are great, it's a bit overkill if you have a huge drive and only a small part of it is used, how about just using tar? of course you will need to setup the bootloader by hand but that should be trivial.

Also check the CentOS Migration Guide.

share|improve this answer
1  
well there is a solution to this issue using dd as well. do a dd if=/dev/zero of=/path/to/drive/zero.img;rm /path/to/drive/zero.img Then when you're using dd to backup the drive, pipe it through gzip this will basically 'eliminate' all of the empty space as well as do great compression. This has the added benefit of cloning the whole HD and not needing to 'install' anything as well as using the smallest amount of space (for dd) possible. –  g19fanatic Dec 21 '10 at 20:41
    
The command tar will ignore hard-link. rsync is better. –  kamae Feb 28 '12 at 8:29
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.