Enterprise Manager allows blackout periods to be specified when monitoring of targets is disabled.
To create a blackout use emcli create_blackout
For example:
$OMS_HOME/bin/emcli create_blackout \ -name="BLACKOUT1" \ -add_targets="server4:host" \ -reason="Enterprise Manager:Agent Patch/Maintenance" \ -propagate_targets \ -schedule=duration:-1 Blackout "BLACKOUT1" created successfully
The reason must be specified and must be from the list of available blackout reasons
If the schedule is set to a duration of -1 then the blackout will continue until it is explicitly stopped.
To stop a blackout use emcli stop_blackout. For example:
$OMS_HOME/bin/emcli stop_blackout -name="BLACKOUT1" Blackout "BLACKOUT1" stopped successfully
Note that the blackout is stopped, but not deleted by this command
To restart the blackout it appears to be necessary to delete using emcli delete_blackout and to recreate the blackout using emcli create_blackout
To delete a blackout use emcli delete_blackout. For example:
$OMS_HOME/bin/emcli delete_blackout -name="BLACKOUT1" Blackout "BLACKOUT1" deleted successfully
Note that a blackout must be stopped before it can be deleted.
To list all currently configured blackouts use emcli get_blackouts
For example:
$OMS_HOME/bin/emcli get_blackouts Name Created By Status Status ID Next Start Duration Reason Frequency Repeat Start Time End Time Previous End TZ Region TZ Offset 20613931-9237_2015-06-05 17:23:25 <SYSTEM> Ended 11 none -00:01 Added via emctl utility once none 2015-06-05 17:23:25 none 2015-06-05 17:25:26 Europe/London +00:00 BLACKOUT1 SYSMAN Started 4 2015-06-08 09:15:09 -00:01 Enterprise Manager:Agent Patch/Maintenance once none 2015-06-08 09:15:09 none none Europe/London +00:00
To list blackouts currently configured on a specific host use emcli get_blackouts -target
For example:
$OMS_HOME/bin/emcli get_blackouts -target="server4:host" Name Created By Status Status ID Next Start Duration Reason Frequency Repeat Start Time End Time Previous End TZ Region TZ Offset BLACKOUT1 SYSMAN Started 4 2015-06-08 09:15:09 -00:01 Enterprise Manager:Agent Patch/Maintenance once none 2015-06-08 09:15:09 none none Europe/London +00:00
emcli get_blackouts does not report blackouts that have been stopped
A reason must be specified when creating a blackout
Enterprise Manager includes a number of system-provided reasons which can be listed using:
$OMS_HOME/bin/emcli get_blackout_reasons
For example for EM12.1.0.4 the reasons are as follows:
$OMS_HOME/bin/emcli get_blackout_reasons AS: Application Server Bounce AS: Application Server Configuration Change AS: Application Server Emergency AS: Application Server Patch/Maintenance AS: Application Server Upgrade Apps: Application Configuration Change Apps: Application Decommissioning Apps: Application Emergency Apps: Application Password Change Apps: Application Patch/Maintenance Apps: Application Standardization Apps: Application Upgrade Apps: New Application Monitoring DB: Database Cold Backup DB: Database Configuration Change DB: Database Decommissioning DB: Database Emergency DB: Database Password Change DB: Database Patch/Maintenance DB: Database Refresh DB: Database Upgrade DB: Disaster Recovery Node DB: New Database Monitoring Enterprise Manager: Agent Configuration Change Enterprise Manager: Agent Emergency Enterprise Manager: Agent Patch/Maintenance Enterprise Manager: Agent Upgrade Enterprise Manager: OMS Server Configuration Change Enterprise Manager: OMS Server Emergency Enterprise Manager: OMS Server Maintenance Enterprise Manager: OMS Server Patch/Maintenance Enterprise Manager: OMS Server Upgrade Enterprise Manager: Plug-in Upgrade Hardware Configuration Change Hardware Emergency Hardware Failure Hardware Patch/Maintenance Hardware Upgrade Network Configuration Change Network Emergency Network Hardware Failure Network Outage Network Patch/Maintenance Network Upgrade OS Configuration Change OS Emergency OS Password Change OS Patch/Maintenance OS Upgrade Other: Customer Request SLB: Load Balancer Configuration Change SLB: Load Balancer Emergency SLB: Load Balancer Patch/Maintenance SLB: Load Balancer Upgrade Security Patch Server Bounce Server Decommissioning Server Physical Move Storage Filer Upgrade Testing