#!/bin/sh # dumpster -- taking out the garbash with dump(8) # %u is 1=mon 7=sun (unless given in ARGV) LVL=${1:-"$(date +%u)"} BAKDIR="/bak/$(date +%F)_$LVL" mkdir -p "$BAKDIR" dump -$LVL -auf "$BAKDIR/root.dump.$LVL" / dump -$LVL -auf "$BAKDIR/home.dump.$LVL" /home dump -$LVL -auf "$BAKDIR/var.dump.$LVL" /var