Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

cron

Status
Not open for further replies.

buxtonicer1

Programmer
Sep 20, 2006
82
GB
How do I modify cron to run a command every wednesday at 1pm .
 
Set the job to run in cron as:

00 1 * * 3 /path/to/job

I hope that helps.

Mike
 
Sorry mis-read, thought it was 1 am !

try

00 13 * * 3 /path/to/job


Mike
 
Please try man crontab but put simply, fields are:

minute (0-59)
hour (0-23)
day of the month (1-31)
month of the year (1-12)
day of the week (0-6 with 0=Sunday)
command

NB: * = "every"

I hope that helps.

Mike
 
00 13 * * 3 /path/to/job

So its 00 minutes 1 hour 3 of Wednesday .... confused ???


minute (0-59)
hour (0-23)
day of the month (1-31)
month of the year (1-12)
day of the week (0-6 with 0=Sunday)

 
No, 13:00 (ie 1pm) every Wednesday (day 3), every Wednesday (regardless of date). It's not exactly intuitive at first, but once you get used to it, you'll be fine.

Alan Bennett said:
]I don't mind people who aren't what they seem. I just wish they'd make their mind up.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top