0

I recently made a backup of a CentOS 7 server using rsnapshot - version 1.3.1 and rsync -version 3.0.9

I made a few changes to the rsnapshot.conf file, which are listed below.

I uncommented the following lines:

#cmd_cp       /usr/bin/cp
#cmd_ssh      /usr/bin/ssh
#cmd_du       /usr/bin/du
#link_dest    0

And I added the following lines:

backup        /var            localhost/
backup        /srv            localhost/
backup        /root           localhost/

After running the command rsnapshot hourly, I was left with a copy of the following directories, as expected:

/etc /home /root /srv /usr /var

I'm a PHP developer so what I did next will probably hurt all the sysadmins out there.

To test the backup I created a fresh install of CentOS 7 on another server and replaced the 6 directories mentioned above with the 6 from my backup, using the commands:

rsync -av /backup/etc /etc
rsync -av /backup/home /home
rsync -av /backup/root /root
rsync -av /backup/srv /srv
rsync -av /backup/usr /usr
rsync -av /backup/var /var

The directories were successfully overwritten and that was the last time I ever saw that server. It failed to boot after that.

I receive these 4 errors during the failed boot process:

[FAILED] Failed to listen on LVM2 metadata daemon socket.
[DEPEND] Dependency failed for Monitoring of LVM2 mirrors, sn...ogress polling.
[FAILED] Failed to listen on Device-mapper event daemon FIFOs.
[FAILED] Failed to start Activation of DM RAID sets.

So my questions are:

What is the correct procedure to restore a server from a backup made using rsnapshot?

Are there directories that I haven't included in the backup that I should have?

And lastly, which directories or sub-directories, once replaced, are likely to be the ones that caused the server not to boot?

A bit of info that might help:

The server I attempted to backup has 2 users and Apache, PHP and PostgreSQL installed. It also has everything that would be installed as a result of running the following command:

yum –y groupinstall "Base" "Development Libraries" "Development Tools"

Thanks in advance.

ste
  • 381
  • 1
  • 3
  • 8

0 Answers0