0

I am just preparing to move our production system to a new Hardware.

If possible I would prefer to have the same users/userid's on the new Machine. There's also a MySQL Database which is needed on the new Machine.

I am considering to put the harddisk from the new machine into the old production system and then use a diskimager to clone the original harddisk.

Do you that is a good idea? What kind of diskimager would you recommend? And - since the new harddisk is larger then the old one - how can I use the additional space on the new harddisk?

Any other helpful tips how can I do the move without having to much efforts are very appreciated.

Vokuhila-Oliba
  • 193
  • 1
  • 3
  • 10

3 Answers3

1

You can do a dump of your system. I recommend to you to have a kernel not too old.

To simply copy it, boot on a live CD or something similar and run this command :

dd if=/dev/hdx of=/dev/hdy

hdx is your source device and hdy the destination. You also can do it throught an SSH connection :

ssh source_server_ip 'dd if=/dev/sda' | dd of=/dev/sda
Dennis Williamson
  • 62,149
  • 16
  • 116
  • 151
Deimosfr
  • 594
  • 2
  • 5
  • thanks! I am considering to use `CloneZilla`. Have you ever used it for the task? – Vokuhila-Oliba Feb 02 '10 at 20:38
  • 1
    I just used Clonezilla this weekend. It works as advertised. But then again, so does any live distribution with basics like 'dd' and 'netcat'. If you do use dd, make sure to add "bs=4M" to bump up your blocksize, which might improve your throughput. – pboin Feb 02 '10 at 21:16
  • @pBoin: the new harddrive is much bigger then the old one. How can I use the additional space? E.g. can clonezilla enlarge the partitions - for example by using a proportional approach? – Vokuhila-Oliba Feb 02 '10 at 21:22
  • 2
    @Vokuhila-oliba, Simply clone the drive then use something like gparted to extend the drive. Expanding partitions is well covered in other questions. – Zoredache Feb 03 '10 at 00:10
1

Great news! I have been able to move the production system to the new machine without a lot of efforts using clonezilla.

And I did not even have to physically place the new machines hard drive into the production machine. It all worked in a seamless way by using the network.

Additionally clonezilla was able to resize the partitions proportionally on the new drive, see: http://tuxradar.com/content/how-clone-hard-drives-clonezilla

EDIT: clonezilla seems to use use dd as a fallback only. It uses a different approach on a "known" type of file system. This has the advantage of being a lot faster then dd because it doesn't have to include empty blocks.

Vokuhila-Oliba
  • 193
  • 1
  • 3
  • 10
0

I would just partition the new disk, then tar the old disk up and untar onto the new one. Re-run grub to make sure that it installs itself, and you're good to go. No worrying about disk imaging or having to resize partitions.

Bill Weiss
  • 10,979
  • 3
  • 38
  • 66