By default, VestaCP will do a daily backup and store it on the same file system that VestaCP is installed on, which isn't great if something happened to that and that was our reason for wanting to restore!
What we're going to do is set VestaCP to backup to the local storage and also an FTP server.
I've already set up my FTP server, so all I need to do next is change the VestaCP config. First, we need to create the config file:
sudo nano /usr/local/vesta/conf/ftp.backup.conf
And then paste the following into it, keeping in mind that you will need to change the options to match your FTP server:
HOST='backupserver.yourdomain.com' PORT='21' USERNAME='backupuser' PASSWORD='[email protected]' BPATH='/home/backupuser/vestabackup'
Once you've got that done, it's time to let VestaCP know about this, so we're going to edit the config file an add ftp to the list of backup targets:
sudo nano /usr/local/vesta/conf/vesta.conf
Find the line that looks like this:
And change it to this:
Now when VestaCP does its daily backup, it will save it to the FTP server too.