Re: Copying a live system

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Timothy Murphy wrote:
> I want to backup my current CentOS-7.2 system to another drive.
> Is it safe to copy the system while it is running?
> Eg by
> mount /dev/sdb5 /mnt
> rsync -HPaxvz /. /mnt/
> I've found contradictory advice on the web.

Oh, I hit <send> before I added several more things:

First, correct the MAC address in
/etc/udev/rules.d/70-persistant-net.rules (or it might be 60), and in
/etc/sysconfig/network-scripts for ifcfg-<whatever>

Second, you'll need a new /etc/ssh/sshd-host-*

If you're getting your name & IP (and IPv6) from DHCP, don't forget to
update the DHPCD server.


Finally, this works if the system is identical hardware. If not, before
you try to boot, boot from linux rescue, then you need to
chroot /mnt/sysimage

cd /lib/modules

VER=$(ls -rt1 | tail -1)
echo $VER

mkinitrd X $VER
mv X /boot/initrd-$VER.img

At that point, you should be good to go.

       mark

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
https://lists.centos.org/mailman/listinfo/centos



[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux