[Nagiosplug-help] ldap and mysql modules
Stephen Carpenter
scarpe01 at emerald.tufts.edu
Tue Dec 31 11:33:02 CET 2002
Hey,
well this is fun. I am setting up nagios here and ran into a snag. We need
mysql and ldap(s) monitoring. I used a build script that does the following
up to configure:
(on Solaris 8; nagios plugins beta 2)
---cut---
LD_OPTIONS="$LD_OPTIONS -L /usr/local/openssl/lib -R /usr/local/openssl/lib"
LD_OPTIONS="$LD_OPTIONS -L /usr/local/mysql/lib/mysql -R /usr/local/mysql/lib/my
sql"
LD_OPTIONS="$LD_OPTIONS -L /usr/local/openldap/lib -R /usr/local/openldap/lib"
export LD_OPTIONS
CFLAGS="-I/usr/local/openldap/include -lssl -lcrypto"
CFLAGS="$CFLAGS -I /usr/local/mysql/include"
export CFLAGS
./configure --prefix=/usr/local/nagios \
--with-cgiurl=/nagios-bin \
--with-nagios-user=nagios \
--with-nagios-grp=nagios \
--with-mandir=/usr/share/man \
--with-openssl=/usr/local/openssl \
--with-mysql=/usr/local/mysql
---cut---
If I don't use all the LD_OPTIONS and CFLAGS magic, it wont link against
mysql libs (link error) and if I don't use the CFLAGS for crypto and ssl
I get linker errors due to missing symbols (oh yea, and its unable
to find the openldap/mysql includes too)
Now... I have check_mysql and check_ldap...
--- mysql ---
[scarpe01 at azurite libexec]$ ./check_tcp -H XXX -p 3306
TCP OK - 0.014 second response time on port 3306|time= 0.014
[scarpe01 at azurite libexec]$ ./check_mysql -H XXX
Segmentation Fault
------
--- ldap ----
[scarpe01 at azurite libexec]$ ./check_tcp -H XXX -p 389
TCP OK - 0.014 second response time on port 389|time= 0.014
[scarpe01 at azurite libexec]$ ./check_ldap -H ldap-dev.usg.tufts.edu -p 389 -b "dc=tufts,dc=edu"
check_ldap: could not parse arguments
Usage: check_ldap -H <host> -b <base_dn> -p <port> [-a <attr>] [-D <binddn>]
[-P <password>] [-w <warn_time>] [-c <crit_time>] [-t timeout]
(Note: all times are in seconds.)
[scarpe01 at azurite libexec]$ ./check_ldap -H ldap-dev.usg.tufts.edu -p 389
Segmentation Fault
-----
neither of these leaves me with a warm fuzzy. Anyone got any ideas?
Also, does check_ldap support ldap over ssl? I imagine not given that
crypto and ssl libraries were what I had to force linking against for
ldap (I imagine that means most people don't even compile openldap with
ssl support?)
-Steve
--
"The Creation of the Universe was made possible by a grant from Texas
Instruments. "
-- PBS
More information about the Help
mailing list