[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-users] Creating a Xen image from HDD partition
Yoav Felberbaum wrote: Hello, I know that this is fairly straightforward & supposedly documented elsewhere, but damned if I can find the info using Google. I have a "stock" CentOS 4.4 installed on /dev/sda3 (with a RHEL install on /dev/sda2). How should I create a xen-usable loop image from the CentOS partition? Would the following (paraphrased) command work from RHEL ...? dd if=/dev/sda3 of=/path/to/file.img This is the suckful way to do it. "dd" copies are inefficient, and rely on the new partitions or files being exactly the same size. It's vastly faster and more efficient to use "dd" with skip commands to create a file that contains nothing you care about of the designated size, do a mkfs -t ext3 on that file, mount the file as a loop file system, mount the old partition, and do a "cp -a" or a "rsync" between the partitions. Then unmount them both and use the copy. I understand that certain directories, like /boot, /proc & a couple of others should NOT be in the image. Is there a full list? TIA for any help you are able to provide! They won't be if you're not duplicating a live OS, but only a mounted filesystem. _______________________________________________ Xen-users mailing list Xen-users@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-users
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |