Varnish Nagios Plugin

Install

To use this plugin you need to have varnishstat installed which is installed by default when you install varnish.

Perl is also required for this plugin. If you don’t have Perl installed you can install in by running the command below
sudo apt-get install perl
or
sudo yum install perl

Now you can download the file above and extract it:
wget <a href="http://www.toms-blog.com/wp-content/uploads/2013/07/check_varnish-v1.0.tar.gz">http://www.toms-blog.com/wp-content/uploads/2013/07/check_varnish-v1.0.tar.gz</a>
tar -xzf check_varnish-v1.0.tar.gz

Read more

Share

Nagios JBoss Plugin

Perl script to check thread and memory usage of a Jboss server.

I didn't like the Jboss checks that I've found which require Java or remote-run, so I wrote this. It's a simple check that looks at memory usage and busy threads. I did this with percentage thresholds to make it dynamic.

Usage: check_jboss_status.pl [-H ] [-P ] [-t ]
[-m
] [-a ]
[-h
]
-H The host to connect to (default: localhost)
-P The port to connect to (default: 8080)
-a The AJP ports to check for (default: 8009)
-h
The HTTP ports to check for (default: 8080,8443)
-t The percentage of threads busy for warning
(default: 80,50)
-m
The percentage of memory used for warning
(default: 80,50)

Read more

Share

Icininga on SSL

 

 

This is intended to be an introduction for implementation of stronger authentication and server security focused around the CGI web interface.

There are many ways to enhance the security of your monitoring server and Icinga environment. This should not be taken as the end all approach to security. Instead, think of it as an introduction to some of the techniques you can use to tighten the security of your system. As always, you should do your research and use the best techniques available. Treat your monitoring server as it were the most important server in your network and you shall be rewarded.

Additional Techniques

Stronger Authentication using Digest Authentication . If you have followed the quickstart guides, chances are that you are using Apache's Basic Authentication. Basic Authentication will send your username and password in "clear text" with every http request. Consider using a more secure method of authentication such as Digest Authentication which creates a MD5 Hash of your username and password to send with each request.

Forcing TLS/SSL for all Web Communication . Apache provides TLS/SSL through the mod_ssl module. TLS/SSL provides a secure tunnel between the client and server that prevents eavesdropping and tampering using strong publickey/privatekey cryptography.

Locking Down Apache Using Access Controls . Consider locking down access to the Icinga box to your IP address, IP address range, or IP subnet. If you require access outside your network you could use VPN or SSH Tunnels. This is a easy and strong to limit access to HTTP/HTTPS on your system.

Read more

Share

Nagios LDAP Monitoring (works for icinga as well)

on commands.cfg file

 

define command {

        command_name check_ldaps

        command_line    $USER1$/check_ldap.pl -H 192.168.0.123 -p 389

}

on your <server.cfg> file-

 

define service{

     use generic-service   ; template name, available by default

     host_name LDAP  ; unique name of the host being defined

     service_description LDAP Daemon   ; description of the host

     check_command check_ldaps

}

But this plugin requires Perl Net::LDAP modules installed. For installation of Net::LDAP perl CPAN module, you read this post

Download the check_ldap.pl from here.

Share

Installing NRPE For Icinga on Ubuntu 10.10 & CentOS 5.5

I currently have Icigna 1.2 (classic, web, and mobile) running on Ubuntu 10.10. I have a few other Linux servers that I would like to monitor as well. There is a good amount of information on installing Nagios and things to accompany it but Icigna documentation and blogs are fewer.

The goal of this post is to document how to install NRPE on a Icinga server (Ubuntu 10.10 x64) and monitor a remote host (CentOS 5.5 x64).

I also want to give credit to two other blog posts I used to get my systems functional and for this post.

fishfood: http://www.fishfood.co.nz/2010/03/howto-install-nagios-nrpe-for-use-with.html

The Geek Stuff: http://www.thegeekstuff.com/2008/06/how-to-monitor-remote-linux-host-using-nagios-30/

Read more

Share

Icinga Sample Host cfg file to monitor Windows Server

define host{
use             windows-server  ; Inherit default values from a template
host_name blk-smsgw ; The name we're giving to this host
alias           Windows Server       ; A longer name associated with the host
address        10.10.10.1    ; IP address of the host
        }

definehostgroup{

alias           Windows Servers ; Long name of the group
members localhost, blk-smsgw     ; Comma separated list of hosts that belong to this group
        }
define service{
use                     generic-service
host_name               blk-smsgw
service_description     NSClient++ Version
check_command           check_nt!CLIENTVERSION
}

Read more

Share

Monitor Windows Service using Nagios (Icinga)

On the Nagios Server edit the file /usr/local/nagios/etc/objects/windows.cfg:

# vi /usr/local/nagios/etc/objects/windows.cfg

Add the following to create a new service definition to monitor the process state of WinVNC.exe (VNC Server):

# Create a service for monitoring the WinVNC.exe process
# Change the host_name to match the name of the host you defined above

define service{
        use                     generic-service
        hostgroup_name          windows-servers
        service_description     VNC
        check_command           check_nt!PROCSTATE!-d SHOWALL -l WinVNC.exe
        }

Add the following to create a new service definition to monitor the Service state of the Print Spooler service:

define service{
        use                     generic-service
        hostgroup_name          windows-servers
        service_description     eTrust ITM Web Access Service
        check_command           check_nt!SERVICESTATE!-d SHOWALL -l "Print Spooler"
        }

To monitor a Service other then the Print Spooler, substitute Print Spooler with how the Name of the service appears in the Services window Name column

Windows_Services

Share

Icinga Resources

http://www.howtoforge.com/icinga-monitoring-solution-installation-and-configuration-on-centos
http://www.kernelhardware.org/nagios-nrpe-to-monitor-remote-linux-server/
http://docs.icinga.org/1.0.1/en/quickstart-icinga.html
http://danielaliaman.com/blog///index.php/install_nrpe_on_debian_host?blog=2
http://nagios.sourceforge.net/docs/3_0/monitoring-publicservices.html
http://winnersdontlose.com/?p=67
http://kedar.nitty-witty.com/blog/10-steps-mysql-monitoring-nagios-installation-configuration
https://sites.google.com/a/blueprint.org/infrastructure/Home/List-of-All-Tasks/Configure-new-Nagios-clients

http://docs.icinga.org/1.2/en/
http://docs.icinga.org/1.2/en/monitoring-windows.html
http://docs.icinga.org/1.2/en/monitoring-routers.html
http://docs.icinga.org/1.2/en/verifyconfig.html
http://docs.icinga.org/1.2/Icinga_v12_en.pdf
http://efwsupport.com/index.php?topic=451.0

http://www.deobfuscate.net/?p=680

http://www.nagios-wiki.de/nagios/plugins/check_http

http://linuxsysadminblog.com/2009/01/monitoring-a-java-application-from-nagios/

http://linuxsysadminblog.com/2009/02/nagios-how-to-check-if-remote-process-is-running/

http://techblog.willshouse.com/2012/03/26/nagios-check_dns-example/

Share