New Training: Automate and Schedule Jobs
In this 3-video skill, CBT Nuggets trainer Shawn Powers teaches you how to schedule and automate jobs with the system crontab and the at daemon. Learn how to manage one-time operations, along with recurring management processes with native Linux scheduling tools. Watch this new Linux training.
Learn Linux with one of these courses:
This training includes:
16 minutes of training
You’ll learn these topics in this skill:
System-Wide Cron Jobs
Personal Crontabs and the AT Daemon
Handling Foreground and Background Processes
5 Essential Parts of Every Crontab File
Unix-based operating systems support a great scheduling tool or daemon called cron. Cron jobs are tasks that the scheduling program does at specified intervals. For the most part, cron jobs tend to be system maintenance, or systems administration tasks.
If you’re responsible for performing tasks that are repetitive, like sending a certain email, or checking for patches to security software and pushing it out to the network, or backing up the information in a database, a cron job could do those for you. And since it doesn’t need bathroom breaks, post-it notes or phone alarms, it’ll be done more reliably, and exactly on time.
Every cron job depends on a crontab (cron table) file — it’s a text file that schedules jobs to be done. There are system-wide crontab files, and they differ slightly in syntax from user crontabs. But both types depend on the field in which you specify what’s to be done and when, including the day of the week, the month, the day of the month, the hour and the minute. Properly written, a crontab file will automate your repetitive tasks exactly as often as you need them done.
delivered to your inbox.