LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   How often does this cron run (https://www.linuxquestions.org/questions/linux-general-1/how-often-does-this-cron-run-4175459390/)

b_boy 04-24-2013 01:47 AM

How often does this cron run
 
How often does this cron run

04,34 07-18 * * mon-fri /bin/custom.sh

druuna 04-24-2013 02:18 AM

Quote:

Originally Posted by b_boy (Post 4937752)
How often does this cron run

04,34 07-18 * * mon-fri /bin/custom.sh

- 0 times a day (on Saturday and Sunday),
- 22 times a day (on Monday -> Friday),
- 110 times a week,
- 5720 times a year.

- Linux / Unix Command: crontab
- Crontab – Quick Reference
- DuckDuckGo

b_boy 04-24-2013 02:23 AM

Quote:

Originally Posted by druuna (Post 4937766)
- 0 times a day (on Saturday and Sunday),
- 22 times a day (on Monday -> Friday),
- 110 times a week,
- 5720 times a year.

- Linux / Unix Command: crontab
- Crontab – Quick Reference
- DuckDuckGo

thanks for the reply

Can you tell me what times it run? is it every 30 min between 07:00 and 18:00

druuna 04-24-2013 02:27 AM

You might want to check the links I provided, all the answer can be found there.

fredak 04-28-2013 04:18 PM

Quote:

Originally Posted by b_boy (Post 4937768)
thanks for the reply

Can you tell me what times it run? is it every 30 min between 07:00 and 18:00


yes !


does your shell write some timestamp into some logfile ?

if no then you could do as follow :

04,34 07-18 * * mon-fri /bin/custom.sh >> /my_path/custom.`date +\%y\%m\%d_\%H:\%M.log`

then you'll see by yourself whenever it runs

rknichols 04-28-2013 05:04 PM

Quote:

Originally Posted by b_boy (Post 4937752)
How often does this cron run

04,34 07-18 * * mon-fri /bin/custom.sh

It will run 24 times each day Monday through Friday, the first at 07:04 and the last at 18:34.


All times are GMT -5. The time now is 03:30 AM.