From 13384666fd61d14235bd256d4de522084f43ed61 Mon Sep 17 00:00:00 2001 From: Petter Reinholdtsen Date: Mon, 14 Nov 2011 10:55:04 +0000 Subject: Improve LDAP server check, not only checking if the TCP port is listening, but also check if the server will reply to searches for the root DSE. --- debian/changelog | 9 ++++++++- nagios-templates.cfg | 6 ++++++ sitesummary-nodes | 4 +++- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 054cbf6..7c3f361 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +sitesummary (0.0.70) UNRELEASED; urgency=low + + * Improve LDAP server check, not only checking if the TCP port is + listening, but also check if the server will reply to searches for + the root DSE. + + -- Petter Reinholdtsen Mon, 14 Nov 2011 11:42:16 +0100 + sitesummary (0.0.69) unstable; urgency=low [ Andreas B. Mundt ] @@ -10,7 +18,6 @@ sitesummary (0.0.69) unstable; urgency=low both cups and cups-client packages installed to enable it. * Change Standards-Version from 3.9.1 to 3.9.2. No changes needed. * Add Catalan translation from Sergi Casbas (Closes: #609714). - * foo -- Petter Reinholdtsen Mon, 14 Nov 2011 11:31:08 +0100 diff --git a/nagios-templates.cfg b/nagios-templates.cfg index 36f59d6..01af7fd 100644 --- a/nagios-templates.cfg +++ b/nagios-templates.cfg @@ -223,6 +223,12 @@ define command{ command_line /usr/lib/nagios/plugins/check_apt } +define command{ + command_name check_ldap_root + command_line /usr/lib/sitesummary/nagios-plugins/check_ldap_root '$HOSTADDRESS$' +} + + define command{ command_name check_kernel_status command_line /usr/bin/perl /usr/lib/sitesummary/nagios-plugins/check_kernel_status diff --git a/sitesummary-nodes b/sitesummary-nodes index 2ff9e37..e99ab05 100755 --- a/sitesummary-nodes +++ b/sitesummary-nodes @@ -304,7 +304,6 @@ sub generate_nagios_config { my %tcpservices = ( 139 => { name => 'samba', package => 'samba' }, - 389 => { name => 'ldap', package => 'slapd' }, 4949 => { name => 'munin', package => 'munin-node' }, ); @@ -485,6 +484,9 @@ sub generate_nagios_config { # check LDAP and LDAPS using the protocol, module present in # nagios-plugins-basic + print_nagios_service_check(0, $hostname, "ldap root DSE", + "check_ldap_root") + if is_pkg_installed($hostid, "slapd"); # Check Squid web proxy print_nagios_service_check($remote, $hostname, "squid", -- cgit v1.2.3