Skip to main content

Schedules

Schedules run commands and power actions on a timer, for example a restart every night at 05:00 or a backup every 6 hours.

How a schedule looks​

Each schedule in the list shows:

  • its name
  • Last run at (never until it first runs)
  • the five cron fields: MINUTE, HOUR, DAY (MONTH), MONTH and DAY (WEEK)
  • a status: ACTIVE or inactive

Create a schedule​

  1. Open Schedules and click Create schedule.
  2. Name it, for example Nightly restart.
  3. Fill in the five cron fields (see below).
  4. Keep it active and save it.
  5. Open the schedule and add one or more tasks.

The cron fields​

A * means "every".

FieldAllowed valuesMeaning
MINUTE0-59Minute of the hour
HOUR0-23Hour of the day, 24-hour clock
DAY (MONTH)1-31Day of the month
MONTH1-12Month of the year
DAY (WEEK)0-6 (or 1-7)Day of the week. Check the value of Sunday on your screen before relying on it.

Useful patterns:

  • */30 in MINUTE means every 30 minutes.
  • 0,30 means at minute 0 and minute 30.
  • 1-5 in DAY (WEEK) means a range of days.

Examples​

What you wantMINUTEHOURDAY (MONTH)MONTHDAY (WEEK)
Every day at 05:0005***
Every 30 minutes*/30****
Every 6 hours, on the hour0*/6***
Every day at 04:00 and 16:0004,16***
First day of every month at 03:00031**
note

The schedule time is not necessarily your local time. After saving, compare Next run with the time you expect and adjust the hour until it matches.

Tasks​

A schedule does nothing until you add tasks. A task can be:

  • Send command: types a command in the server console, for example say Restarting in 5 minutes or save-all.
  • Power action: Start, Restart, Stop or Kill the server.
  • Create backup: makes a backup. This needs a free backup slot.

Tasks run in order. Each has a time offset, a wait counted from the previous task.

Example: warned restart every day at 05:00​

Create a schedule named Daily restart with MINUTE 0, HOUR 5, and * in the other fields. Add these tasks:

  1. Send command say The server restarts in 1 minute, offset 0 seconds.
  2. Send command save-all, offset 55 seconds (Minecraft).
  3. Power action Restart, offset 5 seconds.

The steps run roughly one minute after the schedule starts.

Example: backup before restart​

  1. Create backup, offset 0.
  2. Power action Restart, with an offset long enough for the backup to finish (a few minutes for a big server).

Tips​

  • Keep a schedule inactive while you test it, then switch it on.
  • Do not schedule a backup every few minutes: backup slots are limited. Delete old ones from Backups.
  • Once a day is plenty for restarts on most servers.
  • If a schedule did not run, check Last run at and that the schedule is active.