Taking an image or clone of Red Hat server

Dear All ,

We have a linux Server where we have installed all our Softwares and applications.

Now we want to clone this Server to another server or copy the image of it and put it in the another server.So that all the softwares and apps appear in the new server also , rather than re installation.

Kindly let me know , is it possible in linux and also the disadvantages of doing it like this.

Thanks and Regards ,
Rj

Best practice would be to build the new system from scratch and re-deploy applications. the second best option would be to install your applications in a dedicated filesystem/location like /apps and use rsync to copy that over to a new system. Next would be to buy software that will do "bare-metal" copies or backup/restores of linux systems.

If you want to do it quick and dirty, put the existing boot/OS hard drive in a server and a blank identical hard disk. Boot the system in rescue mode, ensure that the good copy of the data (you can use fdisk and look for the one that is partitioned) is on the first disk (/dev/sda) and do:

dd if=/dev/sda of=/dev/sdb

is it a physical or virtual host?

I doubt that re-install everything is a good plan. There is a risk of error and besides, you have to crete everything (all your configs for ntp, mail, groups, sudo rules, syslogs and users even) and the risk is that something gets lost, or a package has been updated, so you don't quite get a clone if you are using on-line resources (Satellite or direct to Red-Hat) to install the packages.

So you want a mksysb (AIX) ignite (HP-UX) etc. type clone on RHEL? Sorry, nothing is supplied. There are options though depending how you are currently running:-
Physical

  • Boot from media
  • Slice your first disk to have a boot partition and a root partition (or LVM managed root and other filesystems is better)
  • Restore a copy of your root and other critical* filesystems
  • Build a new boot image in your boot partition
  • Adjust the loader (usually GRUB)

Virtual

  • Use the VM tools to clone the boot device
  • Bring up the system without network devices defined
  • Change the network definitions
  • Define the network devices for the VM
  • Boot

More practically, there is commercial software that can do this for you. There is Christie Clone Manager and Storix, of which I am familiar, but there may be others too. I have AIX in the estate which I can recover with a mksysb so I use that as my base for all RHEL backups and therefore clones.

Certainly Storix is my favourite, but I have no idea on the cost. It works with physical and virtual servers (can migrate any to any too) and gives you DR capability as well as just cloning. Don't let me sway you to that though, have a look at Christie too and any others out there to make sure you get the one that suits you and the budget best.

Robin

Hi.

At Clonezilla - About you can see if that cloning mechanism is right for you.

The only drawback I found was that it did not understand software RAID (mdadm) and copied the entire partition, block by block (dd), rather than ignoring unused filesystem blocks.

So while impractical for me for a cloned backup, it may be suitable for staging to a new server.

Best wishes ... cheers, drl

2 Likes

Hi All ,

Thanks for all of your replies.

It was informative and good.

Regards ,
Rj

Mondo rescue might be an alternative. It can do restores from physical to virtual as well, with a little bit of tinkering with the drivers.

Mondo Rescue - GPL disaster recovery solution

1 Like

Hi try with image for linux(terabyte). its much faster than clonezilla and ghost for Linux. in our environment, we are using this on daily basis to support desktops/workstations