Closed Thread
Results 1 to 3 of 3

Thread: Cron Job Timing Help

  1. #1
    jitensuthar27 is offline x10Hosting Member jitensuthar27 is an unknown quantity at this point
    Join Date
    Dec 2010
    Posts
    4

    Cron Job Timing Help

    Hey guys,

    I'm fairly new to the whole cron job thing (especially the formatting of the timing). I have two cron jobs set up for PHP list, but basically I want to make sure the timings are correct with X10Hosting's free account limitations.

    Here are just the time portions of the cron jobs:

    */5 00-02,04-23 * * *
    30 03 * * *
    So what I was shooting for is this: Run the 1st job every 5 minutes for every hour EXCEPT at 3 AM. Then, at 3:30AM run the second cron. Actually, it would be better if I can have it run the 1st job every 5 minutes except from like 3:00-3:10 AM where I'll be running the 2nd cron. Basically, I'm trying to fit in the 2nd cron while still keeping the minimum spacing of 5 minutes between jobs. The problem is that I want the first one to run every 5 minutes but I need a small gap to run the 2nd one once a day. Any better way to do this?

    Thanks!
    Last edited by jitensuthar27; 01-31-2011 at 08:21 PM.

  2. #2
    descalzo's Avatar
    descalzo is online now Grim Squeaker descalzo has a brilliant futuredescalzo has a brilliant futuredescalzo has a brilliant future
    Join Date
    Jul 2009
    Location
    Ankh-Morpork
    Posts
    7,634

    Re: Cron Job Timing Help

    Code:
    */5 00-02,04-23 * * *  JobA
    0-25,35-55 3 * * *       JobA
    30 03 * * *                 JobB
    Split JobA into two commands. One for the 3 o'clock hour, and one for the rest.
    Nothing is always absolutely so.

  3. #3
    jitensuthar27 is offline x10Hosting Member jitensuthar27 is an unknown quantity at this point
    Join Date
    Dec 2010
    Posts
    4

    Re: Cron Job Timing Help

    Hadn't even thought of that!

    Just a quick question though.... Does that second line for Job A still run every 5 minutes? There doesn't seem to be any indication in the timing format that it does?

    Thanks again
    Last edited by jitensuthar27; 01-31-2011 at 08:40 PM.

Closed Thread

Similar Threads

  1. Timing Out
    By yana2010 in forum Free Hosting
    Replies: 15
    Last Post: 04-24-2010, 02:55 PM
  2. FTP keeps timing out
    By Luigi-San in forum Free Hosting
    Replies: 6
    Last Post: 02-02-2010, 01:49 PM
  3. PHP timing out
    By adamfek in forum Free Hosting
    Replies: 2
    Last Post: 10-13-2009, 06:48 PM
  4. Bad Timing for a WII
    By Derek in forum Off Topic
    Replies: 4
    Last Post: 04-29-2007, 01:36 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers