Run crontab Every 10 Minutes


Q. How do I run a cron job or a shell script every 10 minutes using Linux / UNIX cron service?

A. cron is a time-based scheduling service in Linux / Unix-like computer operating systems.

Login to UNIX system

Type the following command to enter cronjob:
$ crontab -e
Each cronjob has following syntax:

# +---------------- minute (0 - 59)
# |  +------------- hour (0 - 23)
# |  |  +---------- day of month (1 - 31)
# |  |  |  +------- month (1 - 12)
# |  |  |  |  +---- day of week (0 - 6) (Sunday=0 or 7)
# |  |  |  |  |
  *  *  *  *  *  command to be executed

To get crontab to run a task every 10 minutes you could type as follow
*/10 * * * * /path/to/command
Save and close the file.

Copy from http://www.cyberciti.biz/faq/crontab-every-10-min/

Advertisements
By dbglory Posted in Linux

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s