This page covers the installation of the Proxmox Backup Server in our HomeLab. Our approach will be to run the Proxmox Backup Server (PBS) in a VM on our server and use shared storage on one of our NAS drives to store backups.
Proxmox Backup Server Installation
We used the following procedure to install PBS on our server.
PBS was created using the recommended VM settings in the video. The VM is created with the following resources:
- 4 CPUs
- 4096 KB Memory
- 32 GB SSD Storage (Shared PVE-storage)
- HS Services Network
Once the VM is created, the next step is to run the PBS installer.
After the PBS install is complete, PBS is booted, the QEMU Guest Agent is installed, and the VM is updated using the following commands –
# apt update # apt upgrade # apt-get install qemu-guest-agent # reboot
PBS can now be accessed via the web interface using the following URL –
https://<PBS VM IP Address>:8007
Create a Backup Datastore on a NAS Drive
The steps are as follows –
- Install CIFS utils
# Install NFS share package on Proxmox apt install cifs-utils
- Create a mount point for the NAS PBS store
mkdir /mnt/pbs-store
- Create a Samba credentials file to enable logging into NAS share
vi /etc/samba/.smbcreds ... username=<NAS Share User Name> password=<NAS Share Password> ... chmod 400 /etc/samba/.smbcreds
- Test mount the NAS share in PBS and make a directory to contain the PBS backups
mount -t cifs -o rw,vers=3.0, \ credentials=/etc/samba/.smbcreds, \ uid=backup,gid=backup \ //<nas-#>.anita-fred.n et/PBS-backups \ /mnt/pbs-store mkidr /mnt/pbs-store/pbs-backups
- Make the NAS share mount permanent by adding it to /etc/fstab
vi /etc/fstab ...after the last line add the following line # Mount PBS backup store from NAS //nas-#.anita-fred.net/PBS-backups /mnt/pbs-store cifs vers=3.0,credentials=/etc/samba/.smbcreds,uid=backup,gid=backup,defaults 0 0
- Create a datastore to hold the PBS backups in the Proxmox Backup Server as follows. The datastore will take some time to create (be patient).
- Add the PBS store as storage at the Proxmox datacenter level. Use the information from the PBS dashboard to set the fingerprint.
- The PBS-backups store can now be used as a target in Proxmox backups. NOTE THAT YOU CANNOT BACK UP THE PBS VM TO PBS-BACKUPS.
Setup Boot Delay
The NFS share for the Proxmox Backup store needs time to start before the Backup server starts on boot. This can be set for each node under System/Options/Start on Boot delay. A 30-second delay seems to work well.
Setup Backup, Pruning, and Garbage Collection
The overall schedule for Proxmox backup operations is as follows:
- 03:00 – Run Pruning on the PBS-backups store
- 03:30 – Run PBS Backups on all VMs and LXCs EXCEPT for the PBS Backup Server VM
- 04:00 – Run a standard PVE Backup on the PBS Backup Server VM (run in suspend mode; stop mode causes problems)
- 04:30 – Run Garage Collection on the PBS-backups store
- 05:00 – Verify all backups in the PBS-backups store
Local NTP Servers
We want Proxmox and Proxmox Backup Server to use our local NTP servers for time synchronization. To do this, modify/etc/chrony/chrony.conf to use our servers for the pool. This must be done on each server individually and inside the Proxmox Backup Server VM. See the following page for details.
Backup Temp Directory
Proxmox backups use vzdump to create compressed backups. By default, backups use /var/tmp, which lives on the boot drive of each node in a Proxmox Cluster. To ensure adequate space for vzdump and reduce the load on each server’s boot drive, we have configured a temp directory on the local ZFS file systems on each of our Proxmox servers. The tmp directory configuration needs to be done on each node in the cluster (details here). The steps to set this up are as follows:
# Create a tmp directory on local node ZFS stores # (do this once for each server in the cluster) cd /zfsa mkdir tmp # Turn on and verify ACL for ZFSA store zfs get acltype zfsa zfs set acltype=posixacl zfsa zfs get acltype zfsa # Configure vzdump to use the ZFS tmp dir' # add/set tmpdir as follows # (do on each server) cd /etc vi vzdump.conf tmpdir: /zfsa/tmp :wq