Dump another user's crontab cron
Inspect a service account's jobs as root; note: -u needs root or sudo
crontab -l -u <name> 2>/dev/null || echo 'no crontab'
more cron
all 8 commands →
Run job at boot
( crontab -l 2>/dev/null; echo '@reboot /usr/local/bin/warmup.sh' ) | crontab -
Pipe cron output to syslog
*/5 * * * * /opt/job.sh 2>&1 | /usr/bin/logger -t job
MAILTO and PATH header
crontab - <<'EOF'
MAILTO=ops@example.com
PATH=/usr/local/bin:/usr/bin:/bin
0 3 * * * backup.sh
EOF
Test run-parts dry run
run-parts --test /etc/cron.daily
systemd timer alternative
systemd-run --on-calendar='*-*-* 03:00:00' --unit=backup /opt/backup.sh