A cron job is script on the server that is set to run at specific intervals. When you install Drupal 7, it configures its own cron job that handles many important system tasks, such as:
- Searching for updates to the Drupal core
- Searching for updates to the Drupal modules
- Indexing your website’s content
- Running routine maintenance tasks such as clearing log files
Setting the Frequency of the Cron Drupal 7
By default the cron job in Drupal 7 runs every 3 hours. However, since running the cron job and be intensive on the server, if you do not need to have it run every 3 hours it’s best practice to set a lower time to run. Keep in mind. At any time, you can manually run the cron job which we’ll cover in the next section.
- Log into the Drupal Dashboard
- Go to Configuration >> System >> Cron
- Change the cron job frequency from the drop down menu
- Click “Save configuration”
running the Cron Manually in Drupal 7
Anytime you add content to your site you will want to run the cron. Since the cron job handles indexing of the content on your site, running the cron will make the newly added content searchable through the search bar on your website.
- Log into your Drupal dashboard
- Go to Configuration >> System >> Cron
- Click “Run cron”
For more step-by-step guides and practical tips, visit our Drupal Education Channel.