#!/bin/bash # The remote backup process # ~~~~~~~~~~~~~~~~~~~~~~~~~ # Backup the whole of the PostgreSQL database rm -R /home/foo/Backups/firefish/postgresql/*; pg_basebackup -h localhost -p 5432 -U postgres -D /home/foo/Backups/firefish/postgresql -Fp -Xs -P;