Frequently Asked Questions

Help Center Search

Creating a Custom Cron Job

Print this Article
Comment on this Article
Last Updated: August 12, 2008 11:01 AM

Cron is a standard Linux feature that allows you to schedule tasks, called "Cron Jobs," to run unattended at a specified frequency. You can quickly set up a Custom Cron Job schedule using the Cron Manager Feature in the Hosting Control Center. A Custom Cron Job differs from a Basic Cron Job in that you have more control over the frequency at which the task runs.

To Create a Cron Job

  1. Log in to your Account Manager.
  2. In the My Products section, select Hosting.
  3. Next to the hosting account you want to modify, click Manage Account.
  4. In the Content section of the Hosting Control Center, click the Cron Manager icon. This action displays the Cron Manager screen.
  5. Click edit next to the Email Address heading in the left navigation area.
  6. Enter the email address to which you would like to have all information sent regarding this Cron Job.
  7. Click Save.
  8. Click Create Cron Job.
  9. Click Custom.
  10. Enter the required information in each field to schedule the task to run repeatedly at specific intervals.
  11. Cron Job Title
    Enter a name for this Cron Job. Ideally, this title relates to this task, so you can identify it easily.
    Command
    The Command field is the script or executable that runs at a specified frequency. Click Browse to locate a file in your hosting account. The full file name of your selection is placed into this editable field. Click the question mark icon for additional assistance in selecting a command.

    NOTE: Our sample scripts use the variable $HOME. We recommend using $HOME to represent the actual server path, although either can be used.
    Minutes
    Enter the time that you want the Cron Job to run. For example, you can set your job to run at 15 minutes after each hour by selecting "x:15." You can run tasks twice per hour by selecting the Run twice an hour setting. This setting automatically sets tasks to run 30 minutes apart.
    Hours
    Enter the time of day that you want the Cron Job to run. For example, you can set your job to run each day at 1:00 p.m. by selecting "13:xx."
    Day of the Month
    Enter the day of the month that you want the Cron Job to run. For example, you can set your job to run on the 15th of each month by selecting "15."
    Month
    Enter the month that you want the Cron Job to run. For example, you can set your job to run each February by selecting "February."
    Day of the Week
    Enter the day of the week that you want the Cron Job to run. For example, you can set your job to run each Thursday by selecting "Thursday."
  12. Click Save.

Your Cron Job is saved, enabled, and runs at the next scheduled interval.