Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cron trigger to run at half past the hour every hour

Tags:

cron

triggers

Can anyone suggest a way to set a Cron trigger to run at half past the hour every hour?

So far, I've got one working hourly as per "0 0/60 * * * ?".

Am I looking at "0 0/30 * * * ?" at all?

Mr Morgan.

like image 844
Mr Morgan Avatar asked Jul 05 '10 20:07

Mr Morgan


People also ask

What does cron 0 * * * * * mean?

*/5 * * * * Execute a cron job every 5 minutes. 0 * * * * Execute a cron job every hour.


2 Answers

I would use 30 * * * * to run a command half past every hour.

It is worth remembering that in crontab you define a pattern to match the current time against and not an exact time. Every minute crond will awaken and match the current time against your pattern and if there is a match, run your command.

like image 122
Martin Avatar answered Oct 23 '22 23:10

Martin


I recommend using http://www.cronmaker.com/ for painless cron expressions.

like image 22
nelsestu Avatar answered Oct 24 '22 01:10

nelsestu