What is Cronjob?
Cron is a utility in Linux, also known as a cronjob, and is a time-based scheduler in Unix-like operating systems(Linux, Mac OS, etc.) as a pure definition. It simply allows you to schedule the execution of commands on your Linux system at specific intervals or on a schedule. You can create almost any kind of Schedule with the syntax.
1* * * * * /path/to/script.sh 2* * * * * command
Here, The first 5 asterisk signs allow you to control minutes, days, hours, months and days of weeks. The asterisk sign means “Every”. It means that the above-given command and script will run every minute, every hour, every day of the week, all the days in a month, and every month!
You can do */2
to change settings to “alternate”. Or you can set just a number anywhere, Like 1 or 2, to execute a command every 2nd day of a week, 2nd day of a month, 2nd month.
If it is too hard for you, ServerKade has a preset to set the schedule quickly. Finally, let’s see how you can create cronjobs with ServerKade.