In this recipe, we will investigate the role of server automation and the convenience of running specific tasks at predefined periods by introducing you to the time-based job scheduler known as cron. Cron allows for the automation of tasks by enabling the administrator to determine a predefined schedule based on any hour, any day, or any month. It is a standard component of the CentOS operating system, and it is the purpose of this recipe to introduce you to the concept of managing recurring tasks in order to take advantage of this invaluable tool and to make CentOS work for you.
To complete this recipe, you will require a minimal installation of the CentOS 7 operating system with root privileges, and a console-based text editor of your choice. The crontab
program uses Vim for file editing. If you do not know how to work with Vim, go through the tutorial shown in the recipe Introduction to Vim in Chapter 2, Configuring the System.