Let the platform do the work

Schedulers

Overview

Schedulers in Sugar provide users with a method to automate the execution of custom and system processes. Sugar comes with many default schedulers to perform jobs such as monitoring inbound emails, executing workflows, running reports and dispatching campaign emails. Schedulers are available only to administrative users and can be accessed through Admin > Schedulers.

Schedulers Fields

The Schedulers module contains a number of stock fields that come out of the box with Sugar. The following definitions are suggested meanings for the fields, but the fields may be leveraged differently to best meet your organization's needs.

Field Description
Active From Time the scheduler begins to be active per day.
Active To Time the scheduler stops being active per day.
Date & Time End Date and Time the scheduler will stop running on the specified interval.
Date & Time Start Date and Time the scheduler will begin running on the specified interval.
Execute If Missed Specifies if a scheduler should be executed during the next cron run in the event that cron did not run at the exact time a job is scheduled for.
Interval How often and when the schedule will run, defaults to every day, every minute.
Job The job to execute on the defined schedule.
Job Name The name or designation of the scheduler.
Status The current status of the scheduler (i.e., Active, Inactive).

Note: Any times configured for schedulers will be based on the admin user's time zone (user id = '1').

Default Schedulers

The default schedulers that packaged with Sugar are required for different activities throughout the application. The following lists the default schedulers and their default settings:

Name Interval Status
Activity Stream Purger On the hour; 04:00; Sunday Inactive
Check Inbound Mailboxes As often as possible. Active
Clean Jobs Queue On the hour; 05:00am Active
Create Future TimePeriods On the hour; 11:00pm Active
Elasticsearch Queue Scheduler As often as possible. Active
Process Time-Aware Schedules On the hour Active
Process Workflow Tasks As often as possible. Active
Prune Database on 1st of Month On the hour; 04:00am; 1st Inactive
Prune Old Record Lists As often as possible Active
Prune Tracker Tables On the hour; 02:00am Active
Publish approved articles & Expire KB Articles On the hour; 05:00am Active
Rebuild Denormalized Team Security Data Every 15 minutes Inactive
Remove diagnostic tool files On the hour; 04:00am; Sunday Active
Remove temporary files On the hour; 04:00am Active
Remove temporary PDF files On the hour; 04:00am Active
Run Active Data Archives/Deletions On the hour; 10:00PM; Saturday Active
Run Email Reminder Notifications As often as possible. Active
Run Nightly Mass Email Campaigns On the hour; From 02:00am to 06:00am Active
Run Nightly Process Bounced Campaign Emails On the hour; From 02:00am to 06:00am Active
Run Report Generation Scheduled Tasks On the hour; 06:00am Inactive
Sugar Heartbeat On the hour; 04:00am Active
SugarBPM™ Scheduled Job As often as possible. Active
Update tracker_sessions Table As often as possible. Active

SugarBPM Scheduled Job

The SugarBPM Scheduled Job is responsible for processes associated with the SugarBPM automation suite. It is active and runs as often as possible by default. The SugarBPM Scheduled Job will check for any active time-based process events in a pending state. If any processes meet this criterion, the scheduler will ensure the process flow continues. For more information about SugarBPM, please refer to the SugarBPM documentation.

Note: SugarBPM events processed by this scheduler will be run by the admin user (user id = '1') in Process History unless the admin user is disabled.

Activity Stream Purger

The Activity Stream Purger scheduler can help manage the number of activity stream records in the database. The scheduler is inactive by default with an interval set to run weekly on Sundays at 4:00 AM when enabled. As your company uses Sugar, the number of activity records will grow considerably over time which can result in performance degradation. For this reason, it is strongly recommended to enable the scheduler and set it to run during off-peak hours or at least once a week to prune older records from the activities table. By default, the scheduler will remove records that are older than 6 months as of the current date from the activities table, and 25,000 records will be removed per scheduler job run. Please note that user posts, comments, and attachments are preserved but all other activity stream records generated from field updates, new record creation, linking/unlinking records will be removed by the scheduler.

You can modify the following Sugar configuration settings if you wish to change the values: 

Check Inbound Mailboxes

The Check Inbound Mailboxes scheduler is active and runs as often as possible by default. This scheduler will retrieve any unread email from active group inbound email accounts configured in the system. Personal and bounce mail accounts are not checked by this scheduler. If the group email account is configured to create cases or to send auto-reply emails, then this scheduler will handle those tasks as well. For more information on how to set up and configure a group inbound email account, please refer to the Email documentation.

Clean Jobs Queue

The Clean Jobs Queue scheduler is active and runs every day at 5:00 AM by default. The jobs queue is essentially a log of when each scheduler has run. This scheduler will go through the job queues and either soft or hard delete old records in the jobs queue. A soft delete is simply hiding the record from Sugar, but keeping it in the database for recovery if necessary. A hard delete is permanently deleting it from the database. Job queue records will be soft and hard deleted by this scheduler with the following criteria:

  • Soft Delete: Completed more than 7 days ago.
  • Hard Delete: Completed more than 21 days ago.

Note: The number of days for a soft and hard delete are configurable through the sugar config files by modifying the values of $sugar_config['jobs']['soft_lifetime'] and $sugar_config['jobs']['hard_lifetime'].

Create Future TimePeriods

The Create Future TimePeriods scheduler is active and runs every day at 11:00 PM by default. When setting up the Forecasts module for the first time, you are prompted with what type of time period (Yearly or Quarterly) and how many future and past time periods you would like. This scheduler runs based off of those settings and creates new time period records as needed for forecast data entry.

For more information about configuring the time periods for forecasting, please refer to the Forecast Configuration documentation.

Elasticsearch Queue Scheduler

The Elasticsearch Queue Scheduler job is active and runs as often as possible by default. New records, revised records, and deleted records are queued to be processed by this scheduler and added to the full-text search index. Though this scheduler is set to run as often as possible, it can take a few moments before changes are available in global search results. For more information about Search, please refer to the Search documentation.

Process Time-Aware Schedules

The Process Time-Aware Schedules job is active and runs hourly. This scheduler processes entries in the time_aware_schedules table, which monitors and regulates time-based functions (e.g., the Status field on purchased line Item records).

Process Workflow Tasks

The Process Workflow Tasks scheduler is active and runs as often as possible by default. This scheduler processes and runs any time elapsed workflows are due to run. If you utilize time-elapsed workflows, it is highly recommended to run this scheduler as often as possible to ensure the workflows are executed quickly.

For more information on creating workflows, please refer to the Workflow Management documentation.

Note: Workflows processed by this scheduler will be run by the admin user (user id = '1') unless the admin user is disabled.

Prune Database on 1st of Month

The Prune Database on 1st of Month scheduler is configured to run at 4:00 AM on the first day of every month but is inactive by default. Sugar implements a soft delete feature when deleting records through the application. Instead of deleting the record right away, the system marks a field called deleted in the database for the record. This scheduler runs through every table in the Sugar database and deletes any record that has this deleted flag. This is beneficial to keep the database small and efficient but will remove the ability to recover accidentally deleted records. If you have a large database, we recommend activating this scheduler and running it once a month for performance.

Prune Old Record Lists

The Prune Old Record Lists scheduler is active and runs as often as possible by default. This scheduler job will clean up backend database entries Sugar uses when generating export files. Such entries that are older than 1 hour from the current date and time will be removed from the record_list database table.

Keeping this scheduler active will help prevent exports from failing due to size limitations.

Prune Tracker Tables

The Prune Tracker Tables scheduler is active and runs daily at 2:00 AM by default. This scheduler will delete data in the tracker tables based on the tracker prune interval. This interval can be set from Admin > Trackers and defaults to 30 days if not set. Any record older than the specified amount of days will be deleted from the following tables:

  • tracker
  • tracker_sessions
  • tracker_perf
  • tracker_queries
  • tracker_tracker_queries

Keeping this scheduler active helps ensure overall system performance is kept at optimum levels, as these tables are continually updated via common actions in the application. For more information on trackers and setting this interval, please refer to the Tracker documentation.

Publish Approved Articles & Expire KB Articles

The Publish Approved Articles & Expire KB Articles scheduler is active and is set to run daily at 5:00 AM by default. This scheduler publishes any Knowledge Base articles that have a status of "Approved" and were scheduled for a later publish date. It also checks for any articles that have reached their expiration date and changes their statuses to "Expired".

Rebuild Denormalized Team Security Data

The Rebuild Denormalized Team Security Data scheduler is inactive by default with an interval set to run every 15 minutes when activated. Team Security denormalization can significantly improve SQL query performance when there are a large number of Teams in an on-site Sugar instance. This feature relies on a separate Team security denormalization table that needs to be updated as records change to ensure Sugar's team security visibility rules are applied properly. When denormalization is enabled via the perfProfile.TeamSecurity.default.use_denorm configuration and inline updates are disabled via perfProfile.TeamSecurity.inline_update, then the Rebuild Denormalized Team Security Data scheduler must be turned on to make sure the table is regularly updated. 

Remove Diagnostic Tool Files

The Remove Diagnostic Tool Files scheduler is active and runs Sundays at 4:00 AM by default. The ./cache/diagnostic directory serves as a temporary directory for data generated by Sugar's Diagnostic Tool, which allows administrators and developers to capture basic system and server configuration details in order to diagnose problems in a Sugar instance. The tool places this data into a zip file on the server. The Remove Diagnostic Tool Files scheduler will remove any of these temporary files from the directory once a week during off-peak hours. For more information about the Diagnostic Tool, please refer to the Diagnostic Tool documentation.

Remove Temporary Files

The Remove Temporary Files scheduler is active and runs daily at 4:00 AM by default. Sugar uses a cache directory to store files such as images, documents, and installable modules uploaded by users. Some of these documents may be large in size and can cause performance issues. This scheduler will remove any unused files that are found in the ./uploads/tmp directory or in most user-configured upload directories. For more information about temporary file storage, please refer to the Advanced Configuration Options documentation.

Remove Temporary PDF Files

The Remove Temporary PDF Files scheduler is active and runs daily at 4:00 AM by default. The ./cache/pdf/ directory serves as a temporary directory for in-progress PDF files generated from reports, quotes, and other parts of Sugar. Upon successful completion of the PDF operation, the file is typically removed from the directory, but there may be circumstances where orphaned PDF files could remain in the directory. This scheduler will remove any PDF files from the directory during off-peak hours.

Run Active Data Archives/Deletions

The Run Active Data Archives/Deletions scheduler is active and runs weekly on Saturdays at 10:00 PM by default. This scheduler will look at the current list of data archive records configured from the Data Archiver module and, for each one that is marked as active, it will perform the specified archive or deletion. The completed jobs will be registered as records in the Archive Runs module and can be viewed from the subpanel of their parent data archiver records.

Note: It is recommended to run this scheduler during low usage or off-hours as it can affect system performance.

Run Email Reminder Notifications

The Run Email Reminder Notifications scheduler is active and runs as often as possible by default. This scheduler will send out email reminders for meetings and calls that have met or passed the reminder time. Meetings and calls need to have a status that does not equal "Held" in order for the email reminder to be sent to invitees.

Run Nightly Mass Email Campaigns

The Run Nightly Mass Email Campaigns scheduler is active and runs on the hour, every hour from 2:00 AM to 6:00 AM by default. This scheduler will process any campaign emails waiting to be sent from the email queue up to the configured batch amount. If the number of emails to send per batch is set to 500, and this scheduler is set to run once an hour, then you will be sending 500 emails per hour. Please configure this scheduler and the number of emails to send per batch to allow the proper amount of email to be sent.

Note: Many email providers place limitations on email send rates such as emails per hour, emails per day, unique recipients, etc. Please check with your email provider to ensure that they will be able to process the volume of emails you desire to send through campaigns.

For more information on setting the number of emails sent per batch, please refer to the Email documentation.

Run Nightly Process Bounced Campaign Emails

The Run Nightly Process Bounced Campaign Emails scheduler is active and runs on the hour, every hour from 2:00 AM to 6:00 AM by default. This scheduler will retrieve any unread email from active bounce inbound mail accounts configured in the system. Bounce email accounts are important for receiving any bounced emails from a campaign. Emails in the bounce mail account must match all of the following criteria to be classified as a bounced email:

  • 'From' email address must contain MAILER-DAEMON or POSTMASTER.
  • 'Remove me' link from the original email must be in the email body.
  • The originating email does not have a campaign activity log type of invalid email or send error.

We recommend setting this scheduler to run at the same time and interval as the Run Nightly Mass Email Campaigns scheduler. For more information on how to set up and configure a bounce inbound email account, please refer to the Email documentation.

Run Report Generation Scheduled Tasks

The Run Report Generation Scheduled Tasks scheduler is inactive by default with an interval set to run daily at 6:00 AM when activated. This scheduler executes any scheduled reports and emails the results to the designated user. If you want to utilize scheduled reports, please enable this scheduler, otherwise, the reports will not be emailed. We recommend running this scheduler as often as possible, this way if someone schedules a report for 6:15 AM, they will not have to wait until 7:00 to receive the report. For more information on scheduling reports, please refer to the Scheduled Reports documentation.

Sugar Heartbeat

The Sugar Heartbeat scheduler is active with an interval set to run daily at 4:00 AM by default. This scheduler ensures that Sugar continues to receive heartbeat information even if no users have logged into your instance in the last three days. When this occurs, the Sugar heartbeat information will be sent automatically when cron runs.

Update tracker_sessions Table

The Update tracker_sessions Table scheduler is active and runs as often as possible by default. This scheduler updates the tracker_sessions table, setting all records that have a date older than six hours to not active. This ensures any user that is inactive for six hours or more will be logged out and their sessions will no longer be active. Please keep in mind that PHP settings on the server may be more restrictive than the six-hour limitation on inactivity this scheduler imposes.

Schedulers Module Tab

Click the Schedulers module tab in the navigation bar, shown after selecting Scheduler in the Admin page, to access the Schedulers list view. You may also click the three-dots menu in the Schedulers module tab to display the Actions, Recently Viewed, and Favorites menus. The Actions menu allows you to perform important actions within the module. The Recently Viewed menu displays the list of schedulers you last viewed in the module. The Favorites menu displays the list of schedulers you most recently marked as favorites in the module.
schedulersmoduletab
The Actions menu allows you to perform the following operations:

Menu Item Description
Create Scheduler Opens the edit view layout to create a new scheduler.
Schedulers Opens the list view layout to search and display schedulers.

Creating Schedulers

There are various methods for creating schedulers in Sugar including via the Schedulers module and via duplication. The full edit view layout opens when creating the scheduler directly from the Schedulers menu and includes all of the relevant fields for your organization's schedulers. Schedulers can be created for built-in jobs within the application or they can be created to call a URL outside of Sugar.

Creating via Schedulers Module

One of the most common methods of scheduler creation is via the Create Scheduler option in the Sugar Scheduler module tab. This opens up the edit view layout which allows you to enter all the relevant information for the scheduler.

Use the following steps to create a scheduler via the Scheduler module:

  1. Navigate to Admin > Scheduler.
  2. Click the three-dots menu in the Sugar Scheduler module tab and select "Create Scheduler".
    createscheduler
  3. Enter appropriate values for the fields in the edit view layout. All required fields are marked with a red asterisk and must be completed prior to saving.
    Note: For more information on setting the advanced options for the interval, please refer to the Advanced Options section.
  4. Once the necessary information is entered, click "Save".
    Schedulers CreatingViaSchedulersModule Save

Creating via Duplication

You can also create a new scheduler by duplicating an existing scheduler record. The Copy option is useful if the scheduler you are creating has similar information to an existing scheduler.

Use the following steps to create a scheduler by duplicating an existing record:

  1. Navigate to a scheduler record's detail view.
  2. Select "Copy" from the Actions menu.
    Scheduler DetailView ActionsMenu Copy
  3. The displayed edit view is pre-populated with the original scheduler's values. Update the necessary fields, then click "Save". For more information on setting the advanced options for the interval, please refer to the Advanced Options section.
    Scheduler DetailView ActionsMenu Copy Save

Viewing Schedulers

There are various options available for viewing scheduler records in Sugar including via Schedulers list view, Schedulers detail view, and Schedulers Recently Viewed menu.

Viewing via List View

The Schedulers list view displays all scheduler records meeting the current search criteria. To access the list view, simply click the Schedulers module tab. While list view shows key scheduler fields, you can click the scheduler's name to open the record in detail view. For more information on viewing scheduler via list view, please refer to the Schedulers List View section.

Viewing via Detail View

The Schedulers detail view displays thorough scheduler information including all scheduler fields followed by the log records of when this scheduler has run. The detail view can be reached by clicking a scheduler record's link from anywhere in the application including from the Schedulers list view. For more information on viewing scheduler via detail view, please refer to the Schedulers Detail View section.

Viewing via Recently Viewed

As you work, Sugar will keep track of which scheduler you have recently viewed. Click the three-dots menu in the Sugar Scheduler module tab to see a list of the three schedulers you most recently viewed. Clicking the scheduler name will open the scheduler in detail view.
recentlyviewedschedulers

Searching Schedulers

The Schedulers list view includes a Basic Search to help you locate records easily and effectively in a module-specific manner. Once the search is performed, the relevant results will be displayed in the Schedulers list view below. Please note that Sugar automatically appends the wildcard character (%) to the end of your search phrase. This allows the system to retrieve all records that start with the keyword entered in the search. If you would like to broaden the search, you can use the wildcard at the beginning of your text as well (e.g., %services). This will pull up any record that has the word "services" in the name, regardless of how it starts or ends.

For more information on using the various search methods as well as how wildcards are used in the different methods, please refer to the Search documentation.

Basic Search offers a few, commonly used fields for a simplified search experience. The buttons in Basic Search panel have the following functions:

  • Search: Click the Search button or press your Return/Enter key to perform the search.
  • Clear: Click the Clear button to clear all criteria from the searchable fields.


Once the search is complete, the relevant results will populate in the list view below the search panel. To see all scheduler records, simply click "Clear" and then "Search" to perform a blank search with no filters.

Schedulers List View

The Schedulers list view displays all scheduler records meeting the current search criteria. You can view the basic details of each scheduler within the field columns.

Pagination

List view displays the current search results broken into pages that you can scroll through rather than displaying potentially thousands of rows at once. To the right just below the search panel, you can see which records of the total results set are currently being displayed. The two single-arrow Next and Previous buttons can be used to scroll through the records page-by-page. The two double-arrow First Page and Last Page buttons allow you to skip to the beginning or the end of your current results.
By default, Sugar displays 20 records per list view page, but administrators can change the number of records displayed via Admin > System Settings. For more information on changing the number of displayed records, please refer to the System documentation.

Checkbox Selection

You can perform several actions on scheduler records directly from the list view by first selecting the desired records. To select individual scheduler records on the Schedulers list view, mark the checkbox on the left of each row. To select or deselect multiple scheduler records in the list view, use the options in the checkbox dropdown menu:

  • Select This Page: Selects all records shown on the current page of scheduler results.
  • Select All: Selects all records in the current search results across all pages of scheduler results.
  • Deselect All: Deselects all records that are currently selected.

Actions Menu

The Actions menu to the right of the checkbox dropdown allows you to perform various actions on the currently selected records.

The options in the Actions menu allow you to perform the following operations:

Menu Item Description
Delete Delete one or more schedulers at a time.
Mass Update Mass update one or more schedulers at a time.
Export Export one or more schedulers to a CSV file.

Favorite Designation

Users have the option to mark scheduler records as favorites via the list view as well as the detail view. This allows users to designate records that are important or will be viewed often so that they can easily be accessed via search or from the Schedulers module tab. In the Schedulers list view, the star on the left of each schedule's row is yellow once marked to indicate a favorite schedule. For more information on marking records as favorites, please refer to the Favoriting Schedulers section of this documentation.

Column Sorting

List view provides the ability to sort all of the current search results by a field column in either ascending or descending order. To sort by a field or switch the sort direction, click the column header noting that the fields which allow sorting will have a pair of arrows. The list view may be sorted by only one column at a time.

Schedulers Detail View

The Schedulers detail view displays thorough scheduler information including all scheduler fields which are grouped by default into the Overview, More Information, and Other panels. You can also view a scheduler's log which appears in beneath the scheduler fields. The detail view can be reached by clicking a scheduler record's link from anywhere in the application including from the Schedulers list view.

Actions Menu

The Actions menu on the top left of each scheduler's detail view allows you to perform various actions on the current record. Administrator users can change the action items to be displayed as separate buttons instead of a dropdown menu via Admin > System Settings. For more information on configuring the actions menu, please refer to the System documentation.
Scheduler DetailView ActionsMenu
The options in the Actions menu allow you to perform the following operations:

Menu Item Description
Edit Edit this scheduler.
Copy Duplicate this scheduler.
Delete Delete this scheduler.

Favorite Designation

Users have the option to mark scheduler records as a favorite via the detail view as well as the list view. This allows users to designate records that are important or will be viewed often so that they can easily be accessed via search or from the Schedulers module tab. In the Schedulers detail view, the star on the right of the scheduler's name is yellow once marked to indicate a favorite scheduler. For more information on how to mark records as favorites, please refer to the Favoriting Schedulers section of this documentation.

Next or Previous Record

On the upper right of the Schedulers detail view, there are two buttons that allow you to page through each scheduler in the Schedulers list view's current search results. Clicking the Previous button displays the previous scheduler of the current search results while clicking the Next button displays the next scheduler of the current search results. The text in between shows which scheduler result you are currently viewing within the total number of current results.

Job Log

Beneath the scheduler's fields is a subpanel with up-to-date entries of when the scheduler was run and information specific to each scheduler job. You can view the details of each job within the field columns (e.g., Job Status, Result), such as the status (e.g., done) of the job, the outcome (e.g., success) of the job, any messages with additional information, and the date/time of when the job was executed or modified.
Schedulers JobLog

Editing Schedulers

Schedulers may be edited at any time to update or add information to the record. You can make changes to existing scheduler records via the Schedulers edit view and quick-create forms. Edit view is available within the Schedulers module and includes all of the Scheduler fields you should need.

Quick Create is available for editing schedulers from outside the Schedulers module and opens as a pop-up without navigating away from your current page. It generally contains fewer fields, but the Full Form button may be used to access the full edit view should you need to edit additional fields.

For more information on setting the advanced options for the interval, please refer to the Advanced Options section.

Editing via Detail View

You can edit schedulers via the detail view by clicking the Edit button on the upper left of the page. Once the edit view layout is open, update the necessary fields, then click "Save" to preserve your changes.

Editing via List View

You can edit schedulers via the list view by clicking the Pencil icon to the left of each scheduler's name. A pop-up window will open with the quick create form which is a shortened version of the edit view layout. Update the necessary fields, then click "Save" to preserve your changes.

Deleting Schedulers

If a scheduler record is invalid and should no longer appear in your organization's Sugar instance, it may be deleted from either the Schedulers detail view or list view. Deleting via the detail view allows you to delete a single record while the list view allows for mass deleting multiple records at once.

Note: If you wish to disable a scheduler but do not want to delete it, you can set the status to Inactive and it will not run.

Deleting via Detail View

Use the following steps to delete a scheduler record via the detail view:

  1. Navigate to a scheduler record's detail view.
  2. Select "Delete" from the Actions menu.
    Scheduler DetailView ActionsMenu Delete
  3. A pop-up message will display asking for confirmation. Click "Ok" to proceed.

Mass Deleting via List View

Use the following steps to delete one or more scheduler records via the list view:

  1. Navigate to the Schedulers list view by clicking the Schedulers module tab.
  2. Use the Search to find the scheduler records you wish to delete.
  3. Select the desired scheduler records individually or using the checkbox dropdown's options.
  4. Choose "Delete" from the Actions menu.
  5. A pop-up message will display asking for confirmation. Click "Ok" to proceed.

Due to PHP memory limitations on the server, there may be occasions when the application times out while deleting a large number of scheduler records. If you encounter an error when performing this action, we recommend selecting the records in smaller batches.

Exporting Schedulers

Sugar's Export option allows users to download all fields for the selected schedulers to their computers as a CSV (comma-separated values) file. This may be useful when needing to use Scheduler data with other software such as Microsoft Excel. Due to PHP memory limitations on the server, there may be occasions when the application times out while exporting a large number of scheduler records. If you encounter an error when performing this action, we recommend selecting the records in smaller batches.

Schedulers may be exported from the Schedulers list view by selecting "Export" from the Actions menu.

Mass Updating Schedulers

Mass updating allows users to make the same change to multiple scheduler records at once from the Schedulers list view. Currently, only fields with the data type of date, datetime, dropdown, multiselect, and radio may be altered during a mass update. Due to the PHP memory limitations on the server, there may be occasions when the application times out while mass updating a large number of scheduler records. If you encounter an error when performing this action, we recommend selecting the records in smaller batches.
Use the following steps to mass update scheduler records from the list view:

  1. Navigate to the Schedulers list view by clicking the Schedulers module tab.
  2. Use the list view's Search to find schedulers you wish to modify.
  3. Select the desired schedulers individually or using the checkbox dropdown's options.
  4. Choose "Mass Update" from the Actions menu.
  5. Scroll to the Mass Update panel and set values for the fields you wish to alter.
  6. Click "Update" to save the changes to all of the currently selected scheduler records.

Favoriting Schedulers

Each Sugar administrator has the option to designate their own favorite schedulers that are important or will be viewed often. Once records are marked as favorites, you can select your most recent favorites directly from the Sugar Scheduler module tab.

Favoriting via List View

Use the following steps to mark records as favorites via the Schedulers list view:

  1. Navigate to the Schedulers list view by clicking the Schedulers module tab.
  2. Use Search to find the scheduler records you wish to mark as favorites.
  3. Click the star icon on the left of each desired scheduler's row.
  4. To remove the scheduler as a favorite, click the star again to revert it to white.

Favoriting via Detail View

Use the following steps to mark records as favorites via the Schedulers detail view:

  1. Navigate to a scheduler record's detail view.
  2. Click the star icon to the right of the scheduler's name in the upper left of the detail view to designate it as a favorite.
  3. To remove the scheduler as a favorite, click the star again to revert it to white.

Advanced Options

From the edit view of a scheduler, you can select the Advanced Options checkbox to refine the interval of the scheduler as well as configure the Advanced Options panel.

This opens up the crontab notation for the interval field. Crontab notation gives administrators more flexibility to define when and how often the scheduler runs. Crontab notation allows you to enter a value for each time part for the job to run on. You can specify complex values by using the following notations:

Character Description
* Asterisk is used to represent every value for the specified time part. For example, * in the mins field will run every minute.
/ Forward slash is used to represent increments. For example, */15 in the mins field will run every 15 minutes. 30/5 in the mins field will run starting at the 30th minute of the hour and every 5 minutes after.
, Comma is used to specify multiple values. For example, 18,20 in the hrs field will run at 6:00 PM and 8:00 PM.
- Hyphen is used to specify a range of values. For example, 1-6 in the mo field will run from January through June.

Specify the values to run in the following interval fields using cron tab notation:

  • min: Specify the minute of the hour to run on (0-59).
  • hrs: Specify the hour of the day to run on (0-23).
  • date: Specify the day of the month to run on (1-31).
  • mo: Specify the month of the year to run on (1-12).
  • day: Specify the day of the week to run on (0-6).

You may specify any combination of the fields to create the schedule needed to run the job.

Setting up Cron Scheduler

In order for the schedulers to run at the designated times, there needs to be a process running on the server to initiate the schedulers. This backend process will call the cron.php file in Sugar with some specific parameters, and the cron.php file will execute the schedulers as necessary.

Sugar instances hosted on Sugar's cloud service have the cron scheduler set up automatically, but it must be configured for on-site instances. In UNIX systems (MAC and Linux) you can configure crontab to run the schedulers. Navigate to Admin > Scheduler to get the system information necessary to set up the crontab.
Schedulers_ToSetupCrontab1

Note: The scheduler is throttled by default to prevent it from running more often than every 30 seconds. This value is configurable by setting the $sugar_config['cron']['min_cron_interval'] value in the config_override.php file.

Setting Up in Unix/Linux

Use the following steps to set up crontab to run the Sugar schedulers:

  1. From a command prompt, execute the following command:
    crontab -u apache -e
  2. The text editor will launch as the user "apache". If your web server is running under a different user, please adjust the line accordingly.
  3. Add the commands displayed on the Admin > Schedulers page of your Sugar application into the crontab file:
    * * * * * cd /var/www/sugar123; php -f cron.php > /dev/null 2>&1
    Note: Make sure that the path to the root directory of Sugar and to PHP is correct.
  4. Save the changes to the file. This will run the cron job every minute.

You can check crontab to see what commands are being run by executing the following command:

              crontab -u apache -l