aports/cron/postgresql/cron-daily

4 lines
193 B
Bash

#!/bin/sh
/sbin/btrfs subvolume delete /var/lib/postgresql/redxen_snapshots/`date +"%u"`
/sbin/btrfs subvolume snapshot -r /var/lib/postgresql /var/lib/postgresql/redxen_snapshots/`date +"%u"`