kron occurrence

To schedule one or more Command Scheduler commands to run at a specific date and time or a recurring level, use the kron occurrence command in Configuration mode. To delete this schedule, use the no form of this command.

kron {occurrence} occurrence-name

Syntax Description

kron

The command to schedule the Command Scheduler commands.

occurrence

Schedules Command Scheduler commands.

occurrence-name

Name of the occurrence. Supports up to 80 alphanumeric characters. (See the following note and Syntax Description.)

Note After you enter the occurrence-name in the kron occurrence command, you enter the config-occurrence configuration submode (see the following Syntax Description).

at

Identifies that the occurrence is to run at a specified calendar date and time. Usage: at [hh:mm] [day-of-week | day-of-month | month day-of-month].

do

EXEC command. Allows you to perform any EXEC commands in this mode (see the “do”).

end

Exits the kron-occurrence configuration submode and returns you to the EXEC mode.

exit

Exits the kron-occurrence configuration mode.

no

Negates the command in this mode.

Three keywords are available:

 • at—Usage: at [hh:mm] [day-of-week | day-of-month | month day-of-month].

 • policy-list—Specifies a policy list to be run by the occurrence. Supports up to 80 alphanumeric characters.

 • recurring—Execution of the policy lists should be repeated.

policy-list

Specifies a Command Scheduler policy list to be run by the occurrence.

recurring

Identifies that the occurrences run on a recurring basis.

Note If kron occurrence is not recurring, then the kron occurrence configuration for the scheduled backup is removed after it has run.

Defaults

No default behavior or values.

Command Modes

Configuration

Usage Guidelines

Use the kron occurrence and policy-list commands to schedule one or more policy lists to run at the same time or interval.

Use the kron policy-list command in conjunction with the cli command to create a Command Scheduler policy that contains the EXEC CLI commands to be scheduled to run on the Cisco CDA server at a specified time. See the “kron policy-list”.

Examples

Note When you run the kron command, backup bundles are created with a unique name (by adding a time stamp) to ensure that the files do not overwrite each other.

Example 1: Weekly Backup

/admin(config)# kron occurrence WeeklyBackup

/admin(config-Occurrence)# at 14:35 Monday

/admin(config-Occurrence)# policy-list SchedBackupPolicy

/admin(config-Occurrence)# recurring

/admin(config-Occurrence)# exit

/admin(config)#

Example 2: Daily Backup

/admin(config)# kron occurrence DailyBackup

/admin(config-Occurrence)# at 02:00

/admin(config-Occurrence)# exit

/admin(config)#

Example 3: Weekly Backup

/admin(config)# kron occurrence WeeklyBackup

/admin(config-Occurrence)# at 14:35 Monday

/admin(config-Occurrence)# policy-list SchedBackupPolicy

/admin(config-Occurrence)# no recurring

/admin(config-Occurrence)# exit

/admin(config)#

Related Commands

Command

Description

kron policy-list

Specifies a name for a Command Scheduler policy.