**DEVELOPMENT OF THIS PLUGIN HAS CEASED AS OF 14/6/2014, IF YOU WOULD LIKE TO TAKE OVER THIS PROJECT PLEASE SEE THE CONTACT US PAGE**
A complex alert integration script for Nagios that can open and update tickets in Service-Now.
Certain meta-characters (most notably the ampersand) will cause the script to fail when trying to parse information to certain fields to Service-Now.
Now requires and loads XML::Simple to resolve some distro compatibility issues. (Thanks KL)
When doing a builddb it now attempts simple authentication when talking to the WSDL. This must have been a security hole fixed in the Service-Now Dublin update. (Thanks KL)
No longer bewildering writes the data-type of extracted fields when doing a builddb to nothing in particular. (Thanks KL)
Fixed Storm Watch database string error preventing it from operating properly when dropping tickets. (thanks AM)
Fixed the script being ignorant of the host UP state. (thanks AM)
Removed unnecessary code.
Fixed several bugs relating to Storm Watch logic.
*NEW* swservice* feature that checks the total tickets for an individual service and suppresses if necessary.
swhost* will now ignore a particular service if it is being too noisy when determining if all the tickets from a particular host need to be suppressed.
swtotal* will now ignore hosts/services that are being too noisy when determining if it needs to suppress tickets.
*NEW* logrotate feature added to assist with creating a log rotate entry.
*NEW* patching feature added to assist when upgrading from old versions to new versions.
*NEW* Ticket Track now hashes incoming messages, this is used to prevent duplicate tickets or updating tickets too regularly.
Updated some of the default settings in config.ini to be more typical for new installs.
Corrected Storm Watch behaviour so that it does a better job of preventing unwanted noise.
Improved logging text to be more useful.
Added additional logic to database clean up.
- First release
Please read the README included in the zip file for full instructions.
Below are the Pre-Install requirements and installation instructions:-
Install the below Perl modules
Service-Now SOAP API must be enabled, refer to Service-Now documentation for more details.
You may additionally need the following perl modules (thanks AM):
Copy the files contained within this zip file to your /usr/local/nagios/libexec/eventhandlers or /usr/local/nagios/libexec directory.
Log in to your database as an administrative user (probably root) then create the service-now ticketer database: CREATE DATABASE nagsnt;
Create a MySQL user for the nagios service-now ticketer database: CREATE USER ‘nagsnt’@‘nagios_ip_address’ IDENTIFIED BY ‘user_password’;
Grant the user priveleges to the database: GRANT ALL PRIVILEGES ON nagsnt.* TO ‘nagsnt’@‘nagios_ip_address’;
Navigate to the directory you extracted the snt files on the Nagios server, open the config.ini file.
Read the configuration section below and set the option in the INI file, save and exit.
Run the table builder: ./sn_ticketer.pl -builddb
Optionally you can use the default field_map.ini settings but in the likely case you need to customize it do one of the following:
- If you are familiar with the service-now page field formats then read the Field mapping section below, then open the field_map.ini and begin mapping.
9a. If you are NOT familiar with the service-now page field formats then create a backup copy of field_map.ini
9b. Open field_map.ini and remove all the default [incident.do] configuration settings, save and exit.
9c. Run the map builder: ./sn_ticketer.pl -page=‘incident.do’ -buildmap
9d. Open the field_map.ini, if everything went well it should now contain all of the available fields for creating incidents.
9e. Remove all of the fields you don’t need and read the Field mapping section below to learn more about configuration.
When upgrading from an older version be sure to run ./sn_ticketer.pl -applypatches
Once this completes, check your config.ini for new options and adjust accordingly.
The page in the field map you wish to use for this alarm.
The host that triggered this alarm, required when ticket track is enabled.
Required option for ticket track to operate properly when the alarm is service related.
The host/service state. Setting this is highly recommended when using ticket track otherwise it won’t operate properly.
If this notification is related to passive data set this flag so that the ticket isn’t kept alive.
Customargs are defined by using the $$ symbols in the fieldmap file. Please see the readme for more details.
Creates the database table required for ticket track operation.
Applies database and config file patches to ensure compatability with latest sn_ticketer version.
Create log rotate entry.
Generate the field mappings for a given Service-Now page.
Display this help text.