Adding Schedule Information
This section explains how to add dates, and times for the schedule to start and stop using the UI forms and with a Cron expression.
Complete the following steps to use the Console to enter basic schedule information. - Open the navigation menu and click Governance & Administration.
- Under Resource Scheduler, click Schedules.
- Under Create a Schedule, click Schedule. The Create a schedule dialog box opens. The default method is to use the UI forms. If it is not selected, click Form Interface. The alternate method is to enter a Cron expression to set the interval, date, and time when the schedule starts or stops.
Using the UI Forms
This page explains how to use the UI forms to add time information to the schedule. See Using a Cron Expression for information about using Cron to set the schedule. - Enter an interval for the schedule.
- In the Interval field, use the menu to select the time interval for the schedule. The choices are:
- One-time
- Hourly
- Daily
- Weekly
- Monthly
Creating a One-time Schedule
- Click in the Interval field to display the menu.
- Select One-time. The one-time dialog box opens.
- In the Time field, enter UTC time in 24-hour format.
- Select the calendar icon to select a date and time that the action specified in the schedule will start.
- Select Next to review the schedule, including the Basic Information, Resources, and Schedule information.
- After reviewing the schedule, click Create to save the schedule. The action (start/stop) runs on the selected resources at the selected date and time.
Creating an hourly schedule
- Click in the Interval field to display the menu.
- Select Hourly. The Hourly dialog box opens.
- In the Time field, enter UTC time in 24-hour format.
- In the Start date field, enter the start date in MM/DD/YYYY format, or use the calendar icon to select a date and time.
- To set the end date, click the End date field and use the calendar to enter the end date and time/
- Click Previous to go back to the Resources screen, or click Next to go to the Review and Save screen, or click Close to delete the schedule without saving it.
Creating a daily schedule
- Click in the Interval field to display the menu.
- Click Daily. The Daily dialog box opens.
- In the Repeat every field, enter how often you would like the schedule to run or use the menu to select an interval. The minimum value is 1. The maximum value is 99.
- In the Day(s) of the week field, click Select... to choose which days(s) of the week to run the schedule. You can select one or more days of the week, one at a time. Click the X next to a displayed name to delete it from the list of selected days.
- In the Start Time field, enter the time in hours and minutes in 24-hour format.
- In the Start date field, enter the start date in MM/DD/YYYY format, or use the calendar icon to select a date and time.
- To set the end date, click the End date field and use the calendar to enter the end date and time/
- Click Previous to go back to the Resources screen, or click Next to go to the Review and Save screen, or click Cancel to delete the schedule without saving it.
Creating a Weekly Schedule
- Click in the Interval field to display the menu.
- Click Weekly. The Weekly dialog box opens.
- In the Repeat every field, either enter how often you want the schedule to repeat. For example, 1 = every week, 2 = every two weeks, 3 = every three weeks. The minimum number of weeks is 1. The maximum number of weeks is 99.
- In the Day(s) of the week field, select the days of the week that you want the schedule to run. You can select one or more days, one at a time. To remove a day, click the X next to the day.
- In the Start date field, use the calendar to select a date and time when the schedule starts.
- Optional: In the End date field, use the calendar to select the date and time that the schedule ends.
- Click Previous to go back to the Resources screen, or click Next to go to the Review and Save screen, or click Close to delete the schedule without saving it.
Creating a Monthly Schedule
- Click in the Interval field to display the menu.
- Click Monthly. The Monthly dialog box opens.
- In the Repeat every field, enter how often you want the schedule to repeat. For example, 1 = every month, 2 = every two months, 3 = every three months. The minimum number of months is 1. The maximum number of months is 99.
- In the Day(s) of the month field, select the number of the day of the month that you want the schedule to run. For example 1 is the first day of the month, 17 is the seventeenth day of the month. You can select one or more days, one at a time. To remove a day, click the X next to the day.
- In the Start Time field, use the calendar to select a date and time when the schedule will start.
- In the End date field, use the calendar to select the date and time that the schedule will end.
- Click Previous to go back to the Resources window, or click Next to go to the Review and Save window, or click Cancel to close the schedule window without saving the schedule.
Using a Cron Expression
This page explains how to use a Cron expression to set the schedule. See Using the UI Forms for information about using the UI forms to set the schedule.
- In the Schedule window, click Cron to display the Cron window.
- Enter a valid Cron expression to set the schedule interval, start date and time, and end date and time. For example, Examples
This expression means every week at 13:30 UTC every Monday, tuesday, Wednesday, Thursday, and Friday.30 13 * * mon-fri
This expression sets the schedule to run every 2 hours on the 15th day of any month.0 */2 15 * *
- In the Start date field, enter the start date manually or use the calendar to select a date
- Optional: In the End date field, enter the end date manually or use the calendar to select a date
- Click Previous to go back to the Resources window, or click Next to go to the Review and Save window, or click Cancel to close the schedule window saving the schedule.
Cron Expression Details
A cron expression is a string of five fields separated by a blank space.
Enter the cron expression in the following format:
You can use the following values in a cron expression:
- <minute>: 0–59
- <hour>: 0–23
- <days of month>: 1–31
- <months>: 1–12 (for January to December)
- <days of week>: 1–7 (for Monday to Sunday)
For example, to run the schedule at 23:00 on the 15th day of any month, enter this expression:
0 23 15 * *
A field can also have the following special characters:Special Characters Character Description * Represents any value. , Separator for more than one value. For example, for <days of week>, 2,3 represents Tuesday and Wednesday. - Range of values. For example, for <days of week>, 1-3 represents Monday through Wednesday. / Step values. For example, for <minute>, */30 represents every 30 minutes. Note
You cannot create a schedule that triggers at an interval of less than 30 minutes. Only intervals of 30 minutes or more are allowed. For example, you can create a schedule with the expression*/30 * 15 * *
to run the schedule every 30 minutes on the 15th day of any month. You cannott, however, define a schedule with*/15 * 15 * *
.For information about creating Cron expressions, see Creating a Cron Expression Schedule.
Use the Resource Scheduler Update Schedule CLI CLI command and required parameters to add resources to a schedule:
oci oci resource-scheduler schedule update --schedule-id, --action, --defined-tags, --description, --display-name, --force, --freeform-tags, -? | -h | --help, --recurrence-details, --resource-filters, --resources, --time-starts
For a complete list of parameters and values for CLI commands, see the CLI Command Reference.
There is no Resource Scheduler API for this task. RS uses iCalendar.org. For a complete list of Resource Scheduler APIs, see Resource Scheduler APIs.