Forums Register Login

Cron Job every five minutes

+Pie Number of slices to send: Send
Hi All,
How can I run crob job every five minutes. Pls advice me with examples.
Thanks
Cheers
Jowsaki
+Pie Number of slices to send: Send
Hi Jowsaki
In the column you want time divided, you put a division sign followed by the division.
I have the following crontab entry to download my email every 5 minutes:

Regards, Andrew
+Pie Number of slices to send: Send
Jus I got a solution from expert-exchange.com. anyhow Thanks Andrew..
+Pie Number of slices to send: Send
Hi Andrew,
I was trying to run the below cron job.. it is givin me an error.. can you pls advice me why?
Am runnin under solaris 8
*/5 * * * * /opt/emg/drivers/driveremg.sh
crontab: error on previous line; unexpected character found in line.
crontab: errors detected in input, no crontab file generated.
Tks
Cheers
Jowsaki
[ June 11, 2003: Message edited by: Sham Jowsaki ]
+Pie Number of slices to send: Send
A typo: the first */ needs to be removed.
Try: "man -S 5 crontab" (or similar) to see the man page for the crontab file format.
-Barry
+Pie Number of slices to send: Send
Hi Jowsaki
Sorry, the example I gave was for Linux, which does allow division:


Step values can be used in conjunction with ranges. Following a range with ``/<number>'' specifies skips of the number's value through the range. For example, ``0-23/2'' can be used in the hours field to specify command execution every other hour (the alternative in the V7 standard is ``0,2,4,6,8,10,12,14,16,18,20,22''). Steps are also permitted after an asterisk, so if you want to say ``every two hours'', just use ``*/2''.


According to Solaris manuals, you will have to use the V7 format (which is rather tedious to type out):

Regards, Andrew
+Pie Number of slices to send: Send
Yes andrew, I did the same thing n it is working fine..
thanks a lot for all your help.
Cheers
Jowsaki
There is no beard big enough to make me comfortable enough with my masculinity to wear pink. Tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 10704 times.
Similar Threads
Do you plan to get iPhone ?
about log4j configuration
T- Shirt Quotes
How to trigger a job every five month
Urgent Java
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 01:04:05.