Netmrg 0.17 RH AS 2.1

bikrant

14-10-2004 02:29:02

Hi
I have installed following packages from source
mysql-4.0.14 -> /usr/local/mysql
net-snmp-5.1.2 -> /usr/local/net-snmp
libxml2-2.6.14 -> /usr/local/libxml

And this is how I configure netmrg-0.17
./configure --prefix=/usr/local/netmrg --with-rrdtool=/usr/local/rrdtool \
--with-mysql-include-dir=/usr/local/mysql/include \
--with-mysql-lib-dir=/usr/local/mysql/lib/mysql \
--with-xml2-include-dir=/usr/local/libxml/include/libxml2 \
--with-xml2-lib-dir=/usr/local/libxml/lib \
--with-snmp-include-dir=/usr/local/net-snmp/include/net-snmp \
--with-snmp-lib-dir=/usr/local/net-snmp/lib \

but I am getting this error message
checking for unistd.h... (cached) yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking for libxml/xmlmemory.h... yes
checking for mysql/mysql.h... yes
checking for an ANSI C-conforming const... yes
checking for size_t... yes
checking return type of signal handlers... void
checking for working memcmp... yes
checking whether lstat dereferences a symlink specified with a trailing slash... yes
checking whether stat accepts an empty string... no
checking for memmove... yes
checking if Net-SNMP needs crypto support... yes
checking if UCD-SNMP needs crypto support... no
checking for CRYPTO_free in -lcrypto... yes
checking for snmp_timeout in -lnetsnmp... no
Cannot find Net-SNMP libraries...checking for UCD-SNMP
checking for snmp_timeout in -lsnmp... no
configure error Cannot find UCD-SNMP libraries

I have net-snmp installed in my system. But why is the configuration script looking for UCD-SNMP??
Distribtion that I am running should not be big problem since I am installing all the dependent package from source.

Any help.

thanks
Bikrant

silfreed

14-10-2004 11:11:47

NetMRG's autoconf looks for UCD-SNMP's libraries if it can't find Net-SNMP's libraries.
Maybe you can look in your config.log (or attach it here) to figure out why it's not finding Net-SNMP's libraries.

-Doug

smo

30-10-2004 13:27:01

Have you installed net-snmp-devel?

keb

30-10-2004 21:48:04

[quote884202b4ec="smo"]Have you installed net-snmp-devel?[/quote884202b4ec]

I think installing from source would also install the header files needed for building NetMRG. If he were using an RPM for RHAS, then he'd need to have net-snmp-devel as well.

bikrant, can you see if it compiles correctly with NetMRG 0.18? If you still receive the error, can you post the relevant portion of the cofig.log file where it tries to test for the snmp_timeout function?

- Kevin

bikrant

31-10-2004 00:56:46

Hi kevin,
I tried the new version (netmrg-0.18) but still same result. I get same error.
I tried ./config ....\
--with-snmp-include-dir=/usr/local/net-snmp/include/net-snmp
and
--with-snmp-include-dir=/usr/local/net-snmp/include
just to make sure.

##########
from config.log
--snip

configure6524 checking for snmp_timeout in -lnetsnmp
configure6554 g++ -o conftest -g -O2 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -I/usr/local/libxml/include/libxml2 -I/usr/local/mysql/include -I/usr/local/net-snmp/include/net-snmp// -L/usr/local/libxml/lib -L/usr/local/mysql/lib/mysql -L/usr/local/net-snmp/lib conftest.cc -lnetsnmp -lcrypto -lmysqlclient -lmysqlclient -lxml2 -lstdc++ -lpthread -lz -ldl >&5
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `EVP_DigestFinal_ex'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `AES_set_encrypt_key'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `EVP_MD_CTX_cleanup'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `EVP_MD_CTX_init'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `DES_cbc_encrypt'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `DES_ncbc_encrypt'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `DES_key_sched'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `AES_cfb128_encrypt'
collect2 ld returned 1 exit status
configure6560 $? = 1

--snip


It seems the error is due to some dpendencies in the ssl library.
I am using openssl-0.9.7d and is installed at /usr/local/ssl

May be i need to recompile ssl and net-snmp again. I'll keep the list updated.

thanks.
Bikrant

keb

31-10-2004 21:25:24

[quote1626ae0ebb="bikrant"]configure6524 checking for snmp_timeout in -lnetsnmp
configure6554 g++ -o conftest -g -O2 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -I/usr/local/libxml/include/libxml2 -I/usr/local/mysql/include -I/usr/local/net-snmp/include/net-snmp// -L/usr/local/libxml/lib -L/usr/local/mysql/lib/mysql -L/usr/local/net-snmp/lib conftest.cc -lnetsnmp -lcrypto -lmysqlclient -lmysqlclient -lxml2 -lstdc++ -lpthread -lz -ldl >&5
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `EVP_DigestFinal_ex'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `AES_set_encrypt_key'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `EVP_MD_CTX_cleanup'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `EVP_MD_CTX_init'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `DES_cbc_encrypt'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `DES_ncbc_encrypt'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `DES_key_sched'
/usr/local/net-snmp/lib/libnetsnmp.so undefined reference to `AES_cfb128_encrypt'
collect2 ld returned 1 exit status
configure6560 $? = 1[/quote1626ae0ebb]

My guess is that your SSL libraries are okay and that there are some missing libraries from the g++ call that need to be added. IIRC, we had a similar DES issue on OpenBSD that required us to add the des library. Try the following to build NetMRG and let us know if it works.

[code11626ae0ebb]LIBS="-ldes" ./configure ...[/code11626ae0ebb]

LIBS should work, but if the outcome is the same and config.log doesn't have -ldes listed as well, use LDFLAGS instead.

- Kevin