PatternCron

Every minute

The finest-grained cron schedule there is: fires every single minute, all day — built for short debugging runs, not for shipping to production.

Last updated

Pattern
* * * * *
Open in Crontab Schedule Creator

In plain English

  • Fires every minute of every hour
  • 1,440 runs per day

Why it’s written this way

All five fields are left as *, so cron imposes no restriction anywhere: any minute, any hour, any day, any month, any weekday. That's the entire expression — the widest-open schedule the format can produce.

Minute is the finest resolution cron understands; there's no field below it. If a job needs sub-minute timing, the job itself has to loop internally — cron just launches it once per qualifying minute.

Edge cases to know

  • →That's 1,440 runs a day — useful for confirming a job's plumbing works, but treat it as a placeholder: widen the schedule (say, */5 or hourly) before this ships anywhere real.
  • →Each firing starts a brand-new process. A job that takes longer than a minute to finish will have its next invocation start before the previous one is done, unless something serializes them.
  • →A minute-by-minute job floods cron's mail or log output fast if MAILTO or logging is on — mute the output deliberately rather than discovering it via a pager alert.

Part by part

* * * * *
Every field unrestricted: minute, hour, day-of-month, month, day-of-week. This is the most frequent schedule cron can express — 1,440 runs a day.

Common mistakes

  • * * * * * /usr/bin/myjob

    No output redirection, so cron mails every minute's output to the local user. On a machine where nobody reads local mail, that quietly fills the spool until the disk does.

    * * * * * /usr/bin/myjob >> /var/log/myjob.log 2>&1
  • * * * * * php artisan schedule:run

    A relative command name depends on PATH, and cron's PATH is minimal — typically just /usr/bin and /bin. The job works when you test it by hand and does nothing on schedule.

  • */1 * * * *

    A step of one is identical to a bare asterisk, so it adds a construct without changing behaviour. It reads as though a deliberate interval was chosen when none was.

Questions

Can cron run more often than once a minute?

No — one minute is its floor, and no syntax extends it. The usual workaround is a job that loops with sleep inside the minute, which is fragile; a long-running worker or a systemd timer with an accuracy setting is the better answer.

Is cron the right tool at this frequency?

Often not. A schedule this tight usually means you want a persistent worker consuming a queue, which starts once, holds its connections, and reacts immediately rather than polling sixty times an hour.

How do I stop runs piling up on each other?

Wrap the command in flock with a lock file, so a slow run blocks the next rather than running alongside it. At this frequency it is not optional — any job occasionally taking over a minute will eventually have several copies competing.

Where does all the output go?

To the user's local mail unless redirected, which at 1,440 messages a day is a real problem. Redirect to a log file with rotation configured, or to a logging service, before enabling a schedule this frequent.

Related in Patterns