Troubleshooting · missed runs

Cron job not running? Diagnose it and catch the next missed run

Check the cron schedule, user, PATH and permissions. Add external missed-run detection even when the script never starts.

Free: 5 monitors, Telegram and email.

Example alert

● daily-report

No signal arrived by the expected deadline. The grace period has elapsed.

Open monitor

Demo data. Message appearance and fields depend on the channel and event type.

When you need this

A notification at the end of a script cannot help if cron never starts the script. First check the scheduler and environment, then set an external deadline for the expected result. A missing message becomes a detectable event.

How to connect

  1. 1

    Check crontab -l as the correct user, the cron/crond service and its logs. Confirm the timezone.

  2. 2

    Run the command with the same permissions, variables and working directory. Use absolute paths and capture stderr in a local log.

  3. 3

    After fixing the cause, add a monitor with the real schedule. Skip one test run and wait for its deadline and grace period.

Ready-to-use example

Install Bash, curl and uuidgen on the job server. Save the code as /opt/tickwatch-run.sh, replace the ping URL with your own and use the absolute path to your job. Keep the ping key private. The wrapper preserves the job exit code; a failed monitoring request does not interrupt it. The cron user must be allowed to write to the chosen local log.

tickwatch-run.sh
#!/usr/bin/env bash
# Save as tickwatch-run.sh; run: bash tickwatch-run.sh /path/to/job.sh
if [ "$#" -eq 0 ]; then echo "Usage: $0 command [args...]" >&2; exit 2; fi
PING='https://ping.tickwatch.dev/YOUR_PING_KEY'
RID=$(uuidgen) || exit 1
ping() {
  curl -fsS --connect-timeout 3 --max-time 5 --retry 2 --retry-max-time 12 \
    -X POST "$PING/$1?rid=$RID" >/dev/null 2>&1 || true
}
finish() {
  code=$?
  trap - EXIT
  if [ "$code" -eq 0 ]; then ping ""; else ping fail; fi
  exit "$code"
}
trap finish EXIT
trap 'exit 130' INT
trap 'exit 143' TERM
ping start
"$@"
Run or configure
0 3 * * * /usr/bin/bash /opt/tickwatch-run.sh /usr/local/bin/job.sh >> /var/log/my-job.log 2>&1

Check before going live

  • The command works manually but not in cron: start with PATH, environment variables and relative paths.

  • There is no execution attempt: check the crontab owner, service state and schedule expression.

  • The job runs late: allow for normal runtime and scheduling delays without masking hours of downtime.

Common questions

Will Tickwatch fix cron automatically?

No. It detects a missing result and alerts you. The cause must be fixed in the scheduler, environment or job code.

Why is failure-only reporting insufficient?

A script must start to report a failure. Deadline monitoring also detects cases where no code ran at all.

Verify your first run while the job still works

Create a monitor, insert your ping URL and check that signals and notifications arrive.

Cron job not running? Diagnose it and catch the next missed run · Tickwatch