InfraBench / system / crontab-inspector

Crontab Paste Inspector

Paste crontab -l or /etc/cron.d/* for instant plain-English explanation & pitfall checks · RAM only, never saved or sent

Actions:
Nothing pasted yet. Input stays strictly in browser RAM and is never stored or included in shared URLs.

Production Crontab Auditing Checklist & Classic Pitfalls

When inheriting legacy Linux servers or investigating overnight incidents, reading raw crontab -l and /etc/cron.d/* files quickly becomes error-prone. This inspector automatically flags the most frequent production cron bugs completely offline inside your browser.

Top 4 Crontab Bugs Caught Automatically

  1. Unescaped Percent Signs (%): Vixie cron treats any unescaped % in the command column as a newline and feeds subsequent text to standard input. Commands like date +%Y%m%d silently fail in cron unless escaped as date +\%Y\%m\%d or wrapped in a shell script.
  2. Day-of-Month + Day-of-Week OR Semantics: Putting values in both fields triggers on EITHER condition rather than their intersection.
  3. Minimal Environment PATH: Cron typically runs with PATH=/usr/bin:/bin, omitting /usr/local/bin, virtualenvs, and user shell profiles. Commands without absolute paths often work interactively yet fail silently under cron.
  4. Overlapping High-Frequency Jobs: Jobs scheduled every minute (* * * * *) can pile up if a single execution stalls. Wrapping commands in flock -n /tmp/job.lock ... prevents stampedes.

User Crontab vs. /etc/cron.d Format

User crontabs edited via crontab -e have 5 schedule fields followed directly by the command. System files placed in /etc/crontab or /etc/cron.d/* include a 6th username column (for example 0 3 * * * root /usr/local/sbin/backup.sh). Toggle the /etc/cron.d format checkbox above when auditing system-wide cron files.

Frequently Asked Questions

Is it safe to paste internal server crontabs here?

Yes. Parsing runs 100% inside local browser JavaScript. Pasted text is never sent over the network, never logged, never saved to localStorage, and never appended to URL query parameters. Reloading the tab wipes memory completely.

How do I convert a legacy crontab entry into a systemd timer?

Click Open in Builder on any parsed row to load its schedule and command directly into the Cron & systemd Timer Lab, which generates ready-to-deploy .service and .timer unit files.