Command won't execute on startup from /usr/local/bin (Ubuntu command line 16.0.4)
2 hours ago, colonel_mortis said:Are there any errors being generated by crontab? Assuming you are running as the babadoctor account, they should be logged to /var/mail/babadoctor.
Is the script executable? if you run ls -l /usr/local/bin/yourScript.sh, does it have x in all the permission masks? If not, try making it executable using chmod +x /usr/local/bin/yourScript.sh.
Are you specifying the whole path in crontab, or just the script name? Try specifying the full path (/usr/local/bin/yourScript.sh) if you aren't already.
So, the solution to this issue was to move it from /usr/local/bin to /usr/bin
It executes the same and works fine.
var/mail/babadoctor is empty.
The script is executable, but has no shebang, as I don't think it needs one. (other /usr/bin script doesnt have one and executes)
I am also executing the entire path in crontab, as it executes the first file fine.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now