mutt), so it is best to switch it to Proxmox's own pmf method.💡 Note
Add other Proxmox hosts to your SSH config to account for custom ports. The proxsave tool will want to connect to at least the other hosts in the cluster.
sudo nano /root/.ssh/config Host proxmox1 192.168.8.3 Port 2222 Host proxmox2 192.168.8.4 Port 2222 Host proxmox3 192.168.6.3 Port 2222 chmod 600 /root/.ssh/config
📌 Note
The backup config for ProxSave is saved on Gitea.
- For a new install, follow the above instructions and then restore the config below.
- For updates (including variable migrations during major changes):
bash -c "$(curl -fsSL https://raw.githubusercontent.com/tis24dev/proxsave/main/install.sh)"- To restore the config, run the following:
# Upgrade/update # Download it from Gitea, it will auto-populate hostname: git clone https://gitea.bachelor-tech.com/jan/proxsave-config.git /opt/proxsave/proxsave-config-backup cd /opt/proxsave/proxsave-config-backup bash /opt/proxsave/proxsave-config-backup/deploy.sh- Check crontab, send output to null in order to not receive two emails per job.
crontab -e 00 02 * * * /usr/local/bin/proxsave >/dev/null 2>&1
🔗 Link
bash -c "$(curl -fsSL https://raw.githubusercontent.com/tis24dev/proxsave/main/install.sh)"
nano /opt/proxsave/configs/backup.env
# Disk space - set min. on secondary storage to be lower than the default 90:
MIN_DISK_SPACE_SECONDARY_GB=5
# Find suspicious ports and if you use port 2222 for SSH, then remove it:
SUSPICIOUS_PORTS="6666 6665 1337 31337 4444 5555 4242 6324 8888 3389 5900"
# Replace the original with these to lower CPU usage:
COMPRESSION_TYPE=zstd
COMPRESSION_LEVEL=12
COMPRESSION_THREADS=0
COMPRESSION_MODE=standard
# For your secondary storage, if you have mounted an NFS share (such as a NAS):
SECONDARY_ENABLED=true
SECONDARY_PATH=/mnt/nas-backup/proxmox1
SECONDARY_LOG_PATH=/mnt/nas-backup/proxmox1/log
# Email Notifications
EMAIL_ENABLED=true
EMAIL_DELIVERY_METHOD=pmf
EMAIL_FALLBACK_SENDMAIL=true
[email protected]
[email protected]
# To disable ZFS warnings if you do not use ZFS:
BACKUP_ZFS_CONFIG=false
/opt/proxmox-backup/configs/backup.env.apt install nfs-common cifs-utils -y
mkdir -p /mnt/nas-backup
# Option 1: As NFS - Linux to Linux (recommended)
mount -t nfs 192.168.8.14:/home/jan/Backups/Proxmox /mnt/nas-backup
# Option 2: As SMB
mount -t cifs -o username=jan,password=YOUR_PASSWORD //192.168.8.14/home/jan/Backups/Proxmox /mnt/nas-backup
# Unmount it
umount /mnt/nas-backup
nano /etc/fstab
# NFS option (do not hang if it not reachable on boot):
192.168.8.14:/home/jan/Backups/Proxmox /mnt/nas-backup nfs hard,intr,timeo=50,retrans=3,_netdev,nofail,x-systemd.automount,x-systemd.mount-timeout=15 0 0
# NFS option (auto-mount of first touch, not on first boot - useful for VPN tunnel
# connections that get established later during uptime
192.168.8.14:/home/jan/Backups/Proxmox /mnt/nas-backup nfs noauto,hard,intr,timeo=50,retrans=3,_netdev,nofail,x-systemd.automount,x-systemd.mount-timeout=15 0 0
# SMB option
//192.168.8.14/home/jan/Backups/Proxmox /mnt/nas-backup cifs username=jan,password=YOUR_PASS,_netdev,nofail,iocharset=utf8 0 0
# Confirm that nothing is mounting on access at this point:
ls /mnt/nas-backup
# Reload systemd
systemctl daemon-reload
# Restart the Remote-FS target service (to activate the automount listener):
systemctl restart remote-fs.target
# Verify that the mounting works
ls /mnt/nas-backup
# Verify that the mounting works
mount -a
ls /mnt/nas-backup
So now we have our local NFS/SMB location ready and can move on to the remote one.
nano /root/.config/rclone/rclone.conf
# Add this line:
bucket_policy_only = true
# Trigger a dry-run:
proxmox-backup --dry-run
(Full path: /opt/proxmox-backup/script/proxmox-backup.sh --dry-run )
proxmox-backup
# Ensure that the backups are on both storage locations and that there are no errors!
# If you get an error related to the lack of existence of corosync.config while
# your host is not running in a cluster, then just create an empty file to prevent
# the script from errorring out:
touch /etc/pve/corosync.conf
# Create a cron job
crontab -e
# Append this line at the end:
0 3 * * 0 /usr/local/bin/proxsave >/dev/null 2>&1
# Install it on the NAS or backup server
sudo apt install nfs-kernel-server -y
# Take into account which user you want the ownership of the files to go to.
# You can use your current non-root user, just check out the ID - let's say it is a 1000
id jan
sudo nano /etc/exports
# Provide access to all the 192.168.x.x subnets and force user 1000 (jan)
/home/jan/Backups/Proxmox 192.168.0.0/16(rw,sync,no_subtree_check,all_squash,anonuid=1000,anongid=1000)
# Apply the changes
sudo exportfs -ar
# Restart the NFS service:
sudo systemctl restart nfs-kernel-server
# Install the tool while still on the NFS server (NAS, backup server..)
sudo apt update && sudo apt install acl -y
# Change the user as you need
sudo setfacl -R -m "default:user:jan:rwx" /home/jan/Backups/Proxmox
sudo setfacl -R -m "default:group:jan:rwx" /home/jan/Backups/Proxmox
# You can always verify the permissions for the given folder
getfacl /home/jan/Backups/Proxmox
showmount -e 192.168.8.14
# Mount it (NFS)
mount -t nfs 192.168.8.14:/home/jan/Backups/Proxmox /mnt/nas-backup
# Try a write operation and remove the file:
touch /mnt/nas-backup/testfile
rm /mnt/nas-backup/testfile
💡 Note
If you try to move a file to the NAS, you will receive an error after copying, as the destination server will not allow permissions changing from the source due to the 'setfacl' that we did earlier.
sudo nano /etc/fstab
192.168.8.14:/home/jan/Backups/Proxmox /mnt/nas-backup nfs hard,intr,timeo=50,retrans=3,_netdev,nofail,x-systemd.automount,x-systemd.mount-timeout=15 0 0
fstab explained:| Option | Why |
|---|---|
nofail |
Systemd won't block boot if this mount fails |
x-systemd.automount |
Mount is lazy, nothing happens at boot at all, it only mounts on first access. This is your real boot-hang fix |
x-systemd.mount-timeout=15 |
If it is accessed and the NAS is unreachable, give up after 15s instead of hanging |
_netdev |
Tells systemd this needs network, orders it correctly |
hard,intr,timeo=50 |
Deliberate choice - keep trying to connect during outage (when already connected) |
fstab changes:systemctl daemon-reload
Simply run the installer script, as per cat /opt/proxmox-backup/README.md | grep -i -A5 "update\|upgrade"
cd /opt/proxmox-backup
bash -c "$(curl -fsSL https://raw.githubusercontent.com/tis24dev/proxmox-backup/main/install.sh)"
rclone config
- Type n for New remote.
- Name: gcp-alias
- Storage: Type alias
- Target: gcp:/proxmox-backup-bachelor/proxmox-backups/proxmox2
- Save and exit
rclone ls gcp-alias