[CentOS] Clone physical into virtual

Wed Aug 8 16:09:18 UTC 2007
Rick Barnes <linux at sitevision.com>

Scott Moseman wrote:
> Is there a formal, or preferred, method for importing a physical
> CentOS machine into a VMware instance?  I know they make
> software to move Windows machines, but I couldn't find one to
> handle our CentOS servers.  I have done something via scp/sftp
> in the past, which *seemed* to work, but if there's a better way
> I'm more than interested in hearing the process.

What has worked for me is to use a liveCD to boot the image and then use
  ssh and tar to clone the machine to the virtual drives. You can find
people suggesting netcat to do it but the ssh /tar method works because
just about every liveCD has ssh and tar. Just mount the drive on the
virt server say /mnt/newroot/, and if you separate images from

from the image run:
# ssh remote.box.com tar c / | tar x -C /mnt/newroot

Adjust the tar attributes as needed.

Rick