The cron expression for every 2 days is 0 0 */2 * *. Here is what each field means, when the job runs next, and how to know if it stops running.
| Field | Value | Meaning |
|---|---|---|
| Minute | 0 | At minute 0 |
| Hour | 0 | At hour 0 |
| Day of month | */2 | Every 2 days: 1, 3, 5, 7 … 31 |
| Month | * | Every month |
| Day of week | * | Every day of the week |
*/2 in the day-of-month field means the 1st, 3rd, 5th … 31st, and it restarts every month: after the 31st comes the 1st, two days in a row. For a strict 48-hour rhythm, run the job daily and let it skip every other day.
Cron doesn't tell you when a job is skipped, crashes or hangs. Create a Hyperping healthcheck in cron mode with 0 0 */2 * * and the job's timezone, add one curl to the end of the job, and you're alerted when a run is missed. Free for up to 20 jobs.
Popular cron schedules:
Every minute • Every 5 minutes • Every 10 minutes • Every 15 minutes • Every 30 minutes • Every hour • Every 2 hours • Every 3 hours • Every 4 hours • Every 6 hours • Every 8 hours • Every 12 hours • Every 24 hours
Every day • Every 2 days • Every 7 days • Every week • Every weekday • Every weekend • At midnight • At noon
Start of month • Twice a month • Every quarter • Every 6 months • Every year • Every leap year
During office hours • Overnight • Every spring • Every fall • Every winter • On Christmas • On New Year
Every 2 minutes • Every 3 minutes • Every 5 hours • Every 16 hours
Related: Cron job monitoring, get alerted when a job misses its schedule