Home Directory Plugins Software check_opswise.py

Search Exchange

Search All Sites

Nagios Live Webinars

Let our experts show you how Nagios can help your organization.

Contact Us

Phone: 1-888-NAGIOS-1
Email: sales@nagios.com

Login

Remember Me

Directory Tree

check_opswise.py

Rating
0 votes
Favoured:
0
Current Version
1.0
Last Release Date
2015-06-24
Compatible With
  • Nagios 4.x
Owner
License
Other
Hits
6233
Files:
FileDescription
check_opswise.pycheck_opswise.py
Network Monitoring Software - Download Nagios XI
Log Management Software - Nagios Log Server - Download
Netflow Analysis Software - Nagios Network Analyzer - Download
Opswise/Universal Automation Center is a product of Stonebranch.
This Python script checks status of all Opswise/UAG agents and alerts if any agent is "Offline". Based on Stonebranch's provided CLI program. Used with Nagios Core.
PreReqs:
1. Python2.7 or above, but below python3.X. Python module argparse required. Tested on RHEL6.

2. Stonebranch's provided CLI program: ops-agent-status 5.2.0 Level 2 Release Build 141 02/16/15 08:31:07 xps 5.2.0 Level 4 Build 110 02/16/15 08:30:42

Installation:
1. Make sure you've met the PreReqs. Edit this script and set you python path.

2. Edit this script and set your Opswise environments to variable: parser.add_argument. Sample config provided for environments: dev, test, acc & prod. Add more if needed. Set your port, unless used default (7878).

3. Copy this script and the ops-agent-status program to your Nagios "libexec" dir, making sure appropriate permissions are set for your "nagios" user.

4. Test the script, I.e:
[nagios@nagios_server libexec]$./check_opswise.py ops-agent-status prod
OK: All UAG agents online.

5. If passed, configure Nagios. Example for configs in services.cfg and commands.cfg below.

# Sample config for services.cfg:
#OPSWISE OpsCli command check ops-agent-status:
define service{
use generic-service
name check_opswise_agent-status_prod
host_name opswiseprod1,opswiseprod2
service_description OPSWISE OpsCli command check ops-agent-status
servicegroups prod_group
check_command check_opswise_agent-status_prod!
max_check_attempts 1
check_interval 5
check_period workhours_7-18
contact_groups admins
notifications_enabled 1
notification_options u,c,r
}

# Sample config for commands.cfg:
define command{
command_name check_opswise_agent-status_prod
command_line $USER1$/check_opswise.py ops-agent-status prod
}