[YLUG] clone fedora 10

Alex Howells alex.howells at 0wn3d.us
Thu Dec 25 15:27:10 UTC 2008


2008/12/25 mike cloaked <mike.cloaked at gmail.com>:
> On Thu, Dec 25, 2008 at 11:35 AM, Patrick Dupre <pd520 at york.ac.uk> wrote:
>> Hello,
>>
>> In the past (ie with fedora 7 and before), I was able to clone a
>> machine by using cp -a. I did the same with fedora 10, but it looks like
>> that it mess up the passwd file and the files related to.
>> In fact the system starts like it should but I cannot login.
>> How can I fix it ?
>
> You will have a tough time doing that!  Particularly since "cp -a"
> does not copy across security contexts so there will be all manner of
> problems since SElinux will prevent you doing a great many normal
> things.
>
> I would suggest that you ask on the Fedora list if anyone can point
> you to some information about cloning a machine - but in any event
> cloning will lead to a situation where the other computer may have
> different hardware - and then the boot process will fail unless you
> re-run mkinitrd to create an initial ramdisk file for the new machine.
>
> Good luck anyway - certainly that is not something I would try to do
> and I would do it very differently.

You can use 'dd' if the disks are identically sized which will handle
most things.

Alternatively 'rsync -vaHPS --numeric-ids' is usually a good
combination but I've no idea if it handles SELinux since I disable
(hell, nuke it from orbit) that on everything - biggest overbearing
pile of tosh to class itself as "required security" ever.

If you use any other method than 'dd' you need to worry about the
master boot record, and Grub.



More information about the York mailing list