hi,
inspired from this thread: rsnapshot + autoshutdown/WOL - flexible daily backups
it tried so setup an anacron job for a daily/weekly/monthly snapshot yesterday.
i dont have my maschine running 24/7. So is started my NAS this morning and the anacron job didnt executed.
after this i trieed to find out why... but now i have to ask you why. from my unterstandings there must by a symlink or a copy in the /etc/cron.daily from the userdefined entry in the /var/lib/openmediavault/cron.d. but there isnt.
After some testing i delete the timestamp files in /var/spool/anacron and reboot the server.
After 5 minutes Anacron start the Daily Job.
root@MIRAMAR:~# cat /var/log/syslog | grep anacron
Jun 29 16:55:05 MIRAMAR anacron[2578]: Anacron 2.3 started on 2016-06-29
Jun 29 16:55:05 MIRAMAR anacron[2578]: Will run job `cron.daily' in 5 min.
Jun 29 16:55:05 MIRAMAR anacron[2578]: Will run job `cron.weekly' in 10 min.
Jun 29 16:55:05 MIRAMAR anacron[2578]: Jobs will be executed sequentially
Jun 29 17:00:05 MIRAMAR anacron[2578]: Job `cron.daily' started
Jun 29 17:00:05 MIRAMAR anacron[4711]: Updated timestamp for job `cron.daily' to 2016-06-29
Jun 29 17:16:12 MIRAMAR anacron[2578]: Job `cron.daily' terminated
Jun 29 17:16:12 MIRAMAR anacron[2578]: Job `cron.weekly' started
Jun 29 17:16:12 MIRAMAR anacron[6082]: Updated timestamp for job `cron.weekly' to 2016-06-29
Jun 29 17:16:14 MIRAMAR anacron[2578]: Job `cron.weekly' terminated (mailing output)
Jun 29 17:16:14 MIRAMAR anacron[2578]: Normal exit (2 jobs run)
Alles anzeigen
For testing i have just two small commands to create a file in Root direktory!
root@MIRAMAR:/var/lib/openmediavault/cron.d# cat userdefined-5ee81b4c-42d9-4b7c-b8fe-093633f8feaf
#!/bin/sh
# This configuration file is auto-generated.
# WARNING: Do not edit this file, your changes will be lost.
echo >/root/daily.txt
root@MIRAMAR:/var/lib/openmediavault/cron.d# cat userdefined-c3abfa10-6ab6-4b83-86dc-6be493b169e2
#!/bin/sh
# This configuration file is auto-generated.
# WARNING: Do not edit this file, your changes will be lost.
echo >/root/weekly.txt
after 10 minutes the weekly Job will execute but still nothing happends.
the only think that works is the weekly job from /etc/cron.weekly/openmediafault-update-smart-drivedb, becaue i got an email of this.
maybe someone has an idea and can help me.
Thanks in advance
PS.: my native language is German. so German allowed? i'm, not sure, sometimes it looks like here are a lot of german people!