Search for and fix phantom downtime
Synopsis
/opt/opsview/support-scripts/bin/phantom_downtime [-u <username>] [-p <password>] [-n] [--debug [0-9]]
Description
This script lists all hosts and services in the system. It then fetches detailed information to check for phantom downtime. If phantom downtime is detected, a new instance of downtime is created on the object for 1 minute. When the new downtime expires naturally, the phantom downtime is removed.
Options
Option | Purpose |
---|---|
-v |
Output version of the script |
-h |
Display help information |
-u <username> |
Username |
-p [password] |
Password. If the password is not provided inline, the user is prompted to provide it. |
--debug [0-9] |
Enable debug output to see the requests and data returned. |
--noapply | -n |
Output what would be done without doing it. |
-U |
If you receive an error about "localhost" or port 3000 use this too e.g. |
Example
opsview@wg-62-ub16-orch:~/supportscripts/bin$ ./phantom_downtime -u admin -p initial
Fetching host list
Pages of 100 hosts fetched: 1/1Hosts: (<hosts downtime issues>/<service downtime issues>/<host ack issues>/<service ack issues>)/<current host>/<total hosts>
Hosts: (0/0/0/0)/24/44
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Configuration Status'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Consolidation Status'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - CPU Time'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - CPU Usage'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - CPU Used'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Disk Latency'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Disk Read/Write'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Disk Usage'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Heartbeat'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Memory Active'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Memory Swap'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Memory Swap Rate'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Memory Usage'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Memory Used'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Network Adapters'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Network Usage'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Power Usage'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Shutdown Status'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Uptime'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Virtual Disk Read/Write'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - Virtual Disk Summary'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - VM Status'
Downtime problem found on 'sol11-build-x86' => 'vSphere - Guest - VMware Tools'
Hosts: (0/23/0/0)/39/44
Downtime problem found on 'wg-v6x-ub16-col4-reverse'
Hosts: (1/23/0/0)/44/44
You have new mail in /var/mail/opsview
Comments
0 comments
Please sign in to leave a comment.