# Schedule Function

### 1. Function Overview

Scheduling functionality is used to execute specific processes when any particular time or event occurs.
This functionality enables the following types of actions using a Yamaha network switch.

- Supplies PoE power to wireless LAN access points only during the specified period.

- Shuts down a port during the specified period.

For information on the functions that can be executed by this product, refer to Function Details and Executable Commands.

### 2. Definition of Terms Used

Trigger

General term for conditions/criteria, such as that the internal clock time matches a specified time or that a specific event occurs.

Time Trigger

Condition that the internal clock time matches a specified time.

Action

Action executed when a trigger is activated.

### 3. Function Details

Scheduling functionality involves specifying “triggers” and actions, which are the two parameter settings for executing specific process “actions” when a particular specified time or event trigger occurs.
This product only supports time trigger.

#### 3.1. Time Trigger

Time triggers can be specified in terms of year, month, day, hour, minute, and second.
Time triggers are specified using the schedule command.
Available setting parameters are indicated below.

Type | Specification method | Setting value example
--- | --- | ---
Date | Month 1-12 | One specific month (such as only December) | 12
Multiple specific months (such as only January and February) | 1,2
Range from specific month to December (such as February to December) | 2-
Range from specific month to specific month (such as February to July) | 2-7
Range from January to specific month (such as January to July) | -7
Every month | *
Day 1-31 | One specific day (such as day 1 only) | 1
Multiple specific days (such as days 1 and 2 only) | 1,2
Range from specific day to last day (such as day 2 to month-end) | 2-
Range from specific day to specific day (such as days 2 to 7) | 2-7
Range from day 1 to specific day (such as days 1 to 7) | -7
Every day | *
Specific day-of-week only (such as Monday only) | mon
Multiple specific days of the week only (such as Saturday and Sundays only) | sat,sun
Range from specific day-of-week to specific day-of-week (such as Monday to Friday) | mon-fri
Range from Sunday to specific day-of-the-week (such as Sunday to Friday) | -fri
Hours, minutes, seconds | Hours 0-23 | Specific hour only (such as 23:00 only) | 23
Multiple specific hours only (such as 01:00 and 22:00 only) | 1,22
Range from specific hour to 23:00 (such as 02:00 to 23:00) | 2-
Range from specific hour to specific hour (such as 02:00 to 21:00) | 2-21
Range from hour 00:00 to specific hour (such as 00:00 to 21:00) | -21
Each hour | *
Minutes 0-59 | One specific minute only (such as minute 59 only) | 59
Multiple specific minutes only (such as minutes 1 and 50 only) | 1,50
Range from specific minute to minute 59 (such as minutes 2 to 59) | 2-
Range from specific minute to specific minute (such as minutes 2 to 50) | 2-50
Range from minute 0 to specific minute (such as minutes 0 to 50) | -50
Each minute | *
Seconds 0-59 | One specific second only (such as second 59 only) This setting may be omitted. | 59

#### 3.2. Action

Processes executed when a time trigger is activated are called actions.
To specify actions, use the schedule template command to switch to the schedule template mode and then specify the action using the cli-command command.
This product supports the following actions.

Action | Command for settings | Description
--- | --- | ---
Executes specified command | cli-command command | Executes the specified commands in ascending order of ID numbers.

### 4. Related Commands

Related commands are indicated below.
For command details, refer to the command reference.

Operating mode | Commands | Description
--- | --- | ---
Global configuration mode | schedule | Specifies a schedule template ID that specifies the trigger and defines the action.
schedule template | Specifies the schedule template ID and switches to the schedule template mode.
Schedule template mode | description | Specifies description of the schedule template.
action | Enables/disables the schedule template. Use disable to temporarily disable schedule function.
cli-command | Defines command executed when trigger is activated.

### 5. Setting Examples

#### 5.1. To supply PoE power to wireless LAN access points only during the specified period (only for PoE-supported models)

Supply PoE power to wireless LAN access points connected to port1.1 and port1.2 on weekdays only between 8:00 and 17:00.

    Yamaha#
    Yamaha# configure terminal
    Yamaha(config)# schedule 1 time */mon-fri 8:00:00 1
    Yamaha(config)# schedule template 1
    Yamaha(config-schedule)# cli-command 1 configure terminal
    Yamaha(config-schedule)# cli-command 2 interface port1.1
    Yamaha(config-schedule)# cli-command 3 power-inline enable
    Yamaha(config-schedule)# cli-command 4 interface port1.2
    Yamaha(config-schedule)# cli-command 5 power-inline enable
    Yamaha(config-schedule)# exit
    Yamaha(config)#
    Yamaha(config)# schedule 2 time */mon-fri 17:00:00 2
    Yamaha(config)# schedule template 2
    Yamaha(config-schedule)# cli-command 1 configure terminal
    Yamaha(config-schedule)# cli-command 2 interface port1.1
    Yamaha(config-schedule)# cli-command 3 power-inline disable
    Yamaha(config-schedule)# cli-command 4 interface port1.2
    Yamaha(config-schedule)# cli-command 5 power-inline disable
    Yamaha(config-schedule)# end
    Yamaha#

#### 5.2. To shut down a port during the specified period

Shut down port1.3 and port1.4 from 17:00 on Friday to 8:00 on the following Monday.

    Yamaha#
    Yamaha# configure terminal
    Yamaha(config)# schedule 1 time */fri 17:00:00 1
    Yamaha(config)# schedule template 1
    Yamaha(config-schedule)# cli-command 1 configure terminal
    Yamaha(config-schedule)# cli-command 2 interface port1.3
    Yamaha(config-schedule)# cli-command 3 shutdown
    Yamaha(config-schedule)# cli-command 4 interface port1.4
    Yamaha(config-schedule)# cli-command 5 shutdown
    Yamaha(config-schedule)# exit
    Yamaha(config)#
    Yamaha(config)# schedule 2 time */mon 8:00:00 2
    Yamaha(config)# schedule template 2
    Yamaha(config-schedule)# cli-command 1 configure terminal
    Yamaha(config-schedule)# cli-command 2 interface port1.3
    Yamaha(config-schedule)# cli-command 3 no shutdown
    Yamaha(config-schedule)# cli-command 4 interface port1.4
    Yamaha(config-schedule)# cli-command 5 no shutdown
    Yamaha(config-schedule)# end
    Yamaha#

### 6. Executable Commands

Only the following commands can be executed for the schedule function.

- configure terminal

- interface

- shutdown

- no shutdown

- power-inline disable (PoE-supported models only)

- power-inline enable (PoE-supported models only)

- write

- end

- exit (This command cannot be executed in the privileged EXEC mode)

### 7. SYSLOG

The schedule function outputs the following SYSLOG messages.

Level | Output | Description
--- | --- | ---
Info | [SCHEDULE]:inf: ID:X command is done | The schedule template ID:X command was executed when the trigger was activated.
Error | [SCHEDULE]:err: Execution failed at schedule template ID: X, cli-command ID: Y. | Execution of cli-command ID: Y failed in the schedule template ID: X.

### 8. Points of Caution

- When actions are executed, the cli-command executes actions in ascending ID number order.

- When actions are executed, even if a command specified by the cli-command results in an execution error, the remaining commands are executed.

- If multiple triggers are activated simultaneously, then actions are executed in ascending order of schedule template ID number.

- If the trigger activation time elapses due to the time setting being set manually by the clock set command or being changed by NTP, then any existing triggers scheduled to be activated within 59 seconds of when the current time setting was changed will be activated.

- If the trigger activation time was changed backward manually by the clock set command or by NTP, then the time triggers are checked again starting from the time to which it was set back.

- This function can be used to periodically save the configuration, but periodic rewriting will consume ROM capacity more quickly. ROM failures due to frequent rewriting are not warranted for free repairs, even if they occur during the warranty period.

### 9. Related Documentation

- None

Search result
No more search results.
There are no topics that match your search query.