Nagios
Plugins
A Nagios plugin that parses the status page of an apache server, the plugin returns the response time, the amount of idle, busy, open and total slots. The perfdata returns the status of all slots including Requests/sec, Bytes/Request and Bytes/sec. Optionally you can specify how much slots should be available. Use http(s) and basic user authentication with non standard server-status urls. This is an enhanced version of an enhanced version of Lieven De Bodt’s check_apachestatus.pl.
Why an extra plugin?
First it uses the ?auto parameter instead of parsing the human readable status output – this reduces possible parsing errors. Then it uses a different syntax of the url parameter. And notably most of all it recalculates the Request/sec and the other values by itself instead of using the given apache server-status values.
Why recalculating the Request/sec vaules?
The Requests/sec and the other values given by the apache server status are calculated by the overall accesses since the uptime of the server, thus reflecting the average values since the server start. Normally a server has a very long uptime and so any access peaks aren’t noted by the given average values. The plugin compares the actual uptime and the access values every time it is called by the previous stored values (/tmp/ folder, change the appropriate value in the script if you need another path) . This returns more precise and actual data.
Examples:
1 2 3 4 5 6 7 |
./check_apachestatus_atuo.pl -H www.myhost.com ./check_apachestatus_auto.pl -H www.myhost.com -w 20 -c 5 ./check_apachestatus_auto.pl -H www.myhost.com -U username -P password ./check_apachestatus_auto.pl -H www.myhost.com -u /administration/apache2 ./check..auto.pl -H ahost.com -u http://admin.bhost.com/ap/server-status?auto |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
./check_apachestatus_auto.pl -h Apache Monitor for Nagios version 1.2 GPL licence, (c)2009 Dennis D. Spreen Usage: ./check_apachestatus_auto.pl -H [-p ] [-t ] [-w -c ] [-V] [-u ] [-U user -P pass -r realm] -h, --help print this help message -H, --hostname=HOST name or IP address of host to check -p, --port=PORT Http port -u, --url=URL Specific URL to use, instead of the default http://hostname/server-status -U, --user=user Username for basic auth -P, --pass=PASS Password for basic auth -r, --realm=REALM Realm for basic auth -X, --proxy=PROXY Proxy-URL for http and https (mandatory) -t, --timeout=INTEGER timeout in seconds (Default: 15) -w, --warn=MIN number of available slots that will cause a warning -1 for no warning -c, --critical=MIN number of available slots that will cause an error -V, --version prints version number Note : The script will return * Without warn and critical options: OK if we are able to connect to the apache server's status page, CRITICAL if we aren't able to connect to the apache server's status page * With warn and critical options: OK if we are able to connect to the apache server's status page and #available slots > , WARNING if we are able to connect to the apache server's status page and #available slots <= , CRITICAL if we are able to connect to the apache server's status page and #available slots <= , UNKNOWN if we aren't able to connect to the apache server's status page ----------------------------------------------------------------------- |
nagios_mdaemon_stats.exe (win32 NRPE)
A Nagios NRPE plugin that parses the status page of a MDaemon server, the plugin returns the SMTP, POP, Spam, virus, SPF, DK cache, IP cache, LDAP cache and tarpit statistics of the MDaemon mail server.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
MDaemon Statistics Plugin for Nagios v1.0 Win32 (c)2009 Dennis D. Spreen Usage nagios_mdaemon_stats.exe [-h] [-V] [-d delay] [-r retry] [-p path] [-v] -h, --help print this help message -V, --version print version number -d, --delay=delayInMs retry delay (ms) for opening mdaemon dat files (Default: 500) -r, --retry=retrycount retry count for opening MDaemon dat files (Default: 3) -p, --path=directorypath MDaemon dat file directory (Default: use path from Registry key) -v, --verbose Add additional output information (does not affect PerfData) Use -v -v to output all PerfData information on screen as well ----------------------------------------------------------------------- |
nagios_mdaemon_check.exe (win32 NRPE)
A Nagios NRPE plugin that checks the active connections to and from a MDaemon server,
the plugin checks and returns the SMTP, POP, IMAP, WorldClient and Webadmin connections.
WorldClient and Webadmin connection detection is limited because of the stateless
connections to the server.
Example 1:
1 2 3 |
nagios_mdaemon_check.exe -w 30 -c 50 |
Warns if total connections exceed 30 and returns critical if >=50
Example 2:
1 2 3 |
nagios_mdaemon_check.exe -w 30 -c 50 -wSMTPout 20 -cSMTPin 30 |
Warms if total connections exceed 30 or SMTPout connections are greater or equal than 20
and returns critical if total connections are greater or equal to 50 or SMPTin connections
are greater or equal than 30.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
MDaemon Check Plugin for Nagios v1.0/Win32 (c)2009 Dennis D. Spreen (dennis@spreendigital.de) Usage nagios_mdaemon_check.exe -w -c [-wX] [-cX] [-h] [-V] [-d delay] [-r retry] [-p path] [-v] -w, --warn=x warn if total connections >= x -c, --crit=x critical if total connections >= x -wX, --warnX, -cX, --critX=x warn or critical if specified connections >= x replace X with SMTPin, SMTPout, SMTPSSL, SMTPTotal, POPin, POPout, POPSSL, POPTotal, IMAPin, IMAPSSL, IMAPTotal, WCin, WCSSL, WCTotal, WAin, WASSL, WATotal -h, --help print this help message -V, --version print version number -d, --delay=delayInMs retry delay (ms) for opening mdaemon dat files (Default: 500) -r, --retry=retrycount retry count for opening MDaemon dat files (Default: 3) -p, --path=directorypath MDaemon dat file directory (Default: use path from Registry key) -v, --verbose Add additional output information (does not affect PerfData) Use -v -v to print out debug information as well |
About Dennis D. Spreen
Search
Recent Posts
- How to compile Lua 5.4.0 for Android as a dynamic library using Android Studio 4
- Please make inline vars usable for production – fix RSP-28892
- How to compile Lua 5.4.0 as a Mac OS X dynamic library
- How to compile Lua 5.4.0 for Linux as a shared library
- How to compile Lua 5.4.0 for Windows
- Daily Wage – a Spigot/Bukkit plugin that pays out a daily wage
- How to compile Lua 5.3.5 for Windows
- Better Collada exporter for Blender with custom properties
- MOS6502-delphi – a MOS 6502 CPU emulator for Delphi
- Pass a multidimensional array as a parameter (with a hidden caveat)
Categories
Tags
Archives
- May 2020
- March 2020
- June 2019
- March 2017
- August 2016
- July 2016
- June 2016
- January 2016
- September 2015
- February 2015
- January 2015
- October 2014
- September 2014
- August 2014
- May 2014
- March 2014
- February 2014
- November 2011
- June 2011
- February 2011
- March 2010
- September 2009
- August 2009
- July 2009
- May 2009
- March 2009
- February 2009
- January 2009
- November 2008
- October 2008
- February 2008
- June 2007
Delphi Feeds
- Select and edit directory paths in Delphi desktop applications with TTMSFNCDirectoryEdit November 20, 2024
- How To Use WebStencils To EASILY Create Modern, Professional, Superfast Websites November 19, 2024
- Creating Heatmaps in TMS FNC Maps for Delphi November 19, 2024
- Discover C++Builder 12.2 – Asia Pacific Webinar November 19, 2024
- The Horror of finding the right database! Part 2 November 18, 2024
- Using ARM runner to automatically build releases for Raspberry Pi using GitHub Actions November 16, 2024
- Signing and Validating JWTs with Private/Public Keys in Delphi with XData November 16, 2024
- QuickReport Is Back! November 15, 2024
- TMS Cryptography Pack Beta available November 14, 2024
- New Features in TMS FNC Chart: Enhanced Data Integration, Flexibility and Styling November 14, 2024