Trying to get my laptop and also my PC to create an ISO file every Sunday so I can burn straight to DVD for backups.
However I realise becasue they both aren’t on all the time, I cant use cron as if it misses a Sunday, it wont run that sunday so with a bit of googling I found I need to run anacron.
However, I cant find if anacron runs on startup. I believe it does on Ubuntu but I’m not 100% sure.
Secondly, to add the task I have to add it to /etc/anacrontab which I believe would end up looking like this:
# See anacron(8) and anacrontab(5) for details.
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
# These replace cron's entries
1 5 cron.daily nice run-parts --report /etc/cron.daily
7 10 cron.weekly nice run-parts --report /etc/cron.weekly
@monthly 15 cron.monthly nice run-parts --report /etc/cron.monthly
# My Backup Commands
7 10 Backup-Docs /home/chris/ShellScripts/CreateDocsISOFile.sh
where CreateDocsISOFile is this script:-
#!/bin/bash
cd /home/chris/
mkisofs -v -o DocsBackup.iso /home/chris/Documents
Am I correct in my thinking?
EDIT:
Using the command
sudo anacron Docs-Backup
seems to have worked - however how can I check that anacron starts on boot?