Restore Your Server's OS From a Backup
In order to restore your server from the previously created tarball the server must have the same Operating System version loaded on it. This particular method of backup and restore is not meant for bare metal projects that need to restore an Operating System to an empty hard drive. It was actually designed to move a configured Operating System from one hardware platform to another, but also works well for rolling back an operating system to a previous configuration.
Once you have a working Operating System either on a new hardware platform or the same hardware platform move the tarball to the server you want to restore. If you stored the tarball on a USB device or other external storage just reattach the device and mount it. If the tarball is on another linux server use commands like this to copy it to the new server’s hard drive:
mkdir /backups
scp root@original_server:/backups/backup.tgz /backups
Of course replace "original_server" with the appropriate IP address.
Enter the root users password and the transfer will begin.
Once the transfer has completed run this command to extract the tarball thereby restoring the Operating System that the tarball contains:
tar xvpfz /backups/backup.tgz -C /
Complete the process with a reboot and troubleshoot any errors that may come up.
No comments:
Post a Comment