Errol Chadd asked 1 year ago
Title : How to schedule a job in Linux?

Question :

How to schedule a job in Linux?

1 Answers
Ruchin SinhaRuchin Sinha Staff answered 1 year ago

Hi,

Linux Cron utility can be used to schedule a job in Linux. Below are some of the common switched to this utility:

crontab -l : Lists all the jobs that are scheduled in Cron tab for that user
crontab -r: Deletes all the jobs scheduled in the Cron tab for that user
crontabl -e: Edits the crontab file. This opens the Cron Tab utility in the Vim Editor.
crontabl -r: Deletes all the jobs from crontab.

Below format is used to schedules jobs in cron tab:

m h  dom mon dow   command

  • A number (or list of numbers, or range of numbers), m, representing the minute of the hour;
  • A number (or list of numbers, or range of numbers), h, representing the hour of the day;
  • A number (or list of numbers, or range of numbers), dom, representing the day of the month;
  • A number (or list, or range), or name (or list of names), mon, representing the month of the year;
  • A number (or list, or range), or name (or list of names), dow, representing the day of the week; and
  • command, which is the command to be run, exactly as it would appear on the command line.

Thanks,
Ruchin

Cubastion is among a very small number of specialized Siebel CRM Oracle Gold Partners in SME.