Results 1 to 6 of 6

Thread: CRON job marked as UNSAFE and not run

  1. #1
    Join Date
    Jun 2008
    Location
    /earth/europe/uk/england/west-yorkshire/leeds/mystreet/myhouse
    Posts
    248

    Default CRON job marked as UNSAFE and not run



    Please see the screenshot above; I had a working CRON job set up and working but needed to add another series of commands to it (it basically RSYNCs a bunch of folders from one place to another across the network).

    After adding, saving and restarting the CRON service, I'm now getting the error:-
    Code:
    Aug  7 13:30:02 bgrsvr-y /usr/sbin/cron[23879]: (badger_fruit) CMD (/home/badger_fruit/bin/backup-script)
    Aug  7 13:30:02 bgrsvr-y /usr/sbin/cron[23877]: (badger_fruit) UNSAFE (badger_fruit)
    Can anyone offer any additional information why this would be marked as such?

  2. #2
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,683
    Blog Entries
    4

    Default Re: CRON job marked as UNSAFE and not run

    Perhaps you don't own the file or it's writable by other people.

  3. #3
    Join Date
    Jun 2008
    Location
    /earth/europe/uk/england/west-yorkshire/leeds/mystreet/myhouse
    Posts
    248

    Default Re: CRON job marked as UNSAFE and not run

    Hi Ken
    Thanks for the suggestion but i've "ls -l" and it's owner and group are correct

    -rwxr-xr-x 1 badger_fruit users 1234 Aug 7 10:37 backup-script

  4. #4
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    29,734

    Default Re: CRON job marked as UNSAFE and not run

    I can not read the screen shot (looks like terminal output, so cut and paste in the post would have worked perfect).

    Stupid question: why do you restart cron? After changing the crontab with
    Code:
    crontab -e
    nothing is needed.
    Henk van Velden

  5. #5
    Join Date
    Jun 2008
    Location
    /earth/europe/uk/england/west-yorkshire/leeds/mystreet/myhouse
    Posts
    248

    Default Re: CRON job marked as UNSAFE and not run

    I didn't touch the cronjob, i amended the script the cronjob calls. Didn't realise I didn't need to restart the service, just did it!

    Anyway, problem solved - the log file that the called script runs had had it's permissions gnarled up somehow; I discovered this when I tried to run the script manually. Changed/reset the permissions and now it's running fine again!

    Hoorah for me

  6. #6
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    29,734

    Default Re: CRON job marked as UNSAFE and not run

    Quote Originally Posted by badger_fruit View Post
    Hoorah for me
    Hm, hm ...
    Henk van Velden

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •