10

Every one hour (starting from "now") I am able to schedule using this cron expression (expression) using nodejs cron-job.

But I need to set cron every one hour starting from a specific time. For example, say it starts from 3:30 am — can we do this? What will be the cron expression for this? any ideas appreciated

3 Answers 3

10

I suspect that you do not mean "every hour", but "every hour of the day starting 3:30".

30 3-23 * * *

30: the minute, half past the hour
3-23: only between hours 3-23 (inclusive)
*: every day
*: every month
*: every weekday

http://www.manpagez.com/man/5/crontab/

5
  • How we can change this to run every 10 minutes after 3: 30 ? Apr 16, 2019 at 6:29
  • What happens during the hours of 0-3? Oct 15, 2020 at 16:52
  • @SW_user2953243 .. the cron will not run from 0-3 Jan 21, 2021 at 8:57
  • 1
    */10 3-23 * * * @MobasherFasihy this is your answer. Jan 21, 2021 at 9:03
  • I don't think it's possible to create 1 expression to run every 10 minutes starting at 3:30. */10 3-23 * * * starts at 3am, not 3:30.
    – hepcat72
    May 28, 2021 at 11:10
1

Here's the correct way to do so:

30 * * * *

Here's a breakdown:

30: The minute, half past the hour

*: Every hour

*: Every Day

*: Every Month

*: Every Weekday

1

run every hour

0 *  *  *  *    root    /path/to/command

or

@hourly     root    /path/to/command

or run every hour starting at 07:00

0 7 * * *       root    /path/to/command

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .