Anacron Daily won't Execute

  • 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.


    For testing i have just two small commands to create a file in Root direktory!

    Code
    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


    Code
    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!

    • Offizieller Beitrag

    /var/lib/openmediavault/cron.d/ contains scripts that are triggered through /etc/cron.d/


    if if you want daily scripts place them at /etc/cron.daily and make sure they have the executable bit.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!