I have a notify.sh script that looks like:
notify-send "hi welcome"
My crontab notification for 2 PM:
0 14 * * * home/hacks/notify.sh
However, this doesn't work. What is the problem?
|
|
|
Your script is missing a #! line at the start, which is the magic interpreted by the kernel to say which command interpreter is to be used for the script. Make it look like this:
and make sure the script is executable:
Also, since you're asking for this to happen just once a day, is the timezone of the crontab the same as your own timezone? You might find this happening at 2pm GMT. |
|||||
|
|
4 hypothesis:
|
||||
|
|
|
Making crontab running is easy only . Here I am going to say how to run crontab jobs. It is useful for anyone who is stuck on crontab.
To make the script executable, we have to do:
Here i run this script for every one minute ... By doing below script, you can write it in a log file to find whether its working write log
send mail
|
||||
|
|
|
You have to open crontab by the following command:
This will run your script once an hour from 8AM-3PM at 10 minutes past the hour every Monday, Wednesday and Friday. |
||||
|
|
|
Add |
|||
|
|