Ad Widget

Collapse

error compiling zabbix_server

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • acceleratebiz
    Junior Member
    • Oct 2005
    • 12

    #1

    error compiling zabbix_server

    I have all the packages and libraries zabbix requires installed using yum from centos 3.5. Including net-snmp and openssl:
    [zabbix@manager zabbix]$ rpm -qa | grep net-snmp
    net-snmp-libs-5.0.9-2.30E.19
    net-snmp-5.0.9-2.30E.19
    net-snmp-utils-5.0.9-2.30E.19
    net-snmp-devel-5.0.9-2.30E.19
    [zabbix@manager zabbix]$ rpm -qa | grep openssl
    openssl-0.9.7a-33.17
    openssl-devel-0.9.7a-33.17
    [zabbix@manager zabbix]$

    ./configure works fine, but 'make install' gives the following compiler error. Any ideas why? Am I missing some libraries?

    gcc -g -O2 -o zabbix_server -L/usr/lib/mysql -lmysqlclient -lm -lz -L/usr/lib -lnetsnmp evalfunc.o expression.o actions.o zlog.o functions.o server.o ../libs/zbxsysinfo/libzbxsysinfo.a ../libs/zbxsysinfo/linux/libzbxsysinfo2.a ../libs/zbxlog/libzbxlog.a ../libs/zbxpid/libzbxpid.a ../libs/zbxconf/libzbxconf.a ../libs/zbxcrypto/libzbxcrypto.a ../libs/zbxnet/libzbxnet.a pinger/libzbxpinger.a poller/libzbxpoller.a escalator/libzbxescalator.a housekeeper/libzbxhousekeeper.a alerter/libzbxalerter.a timer/libzbxtimer.a trapper/libzbxtrapper.a ../libs/zbxemail/libzbxemail.a ../libs/zbxdbhigh/libzbxdbhigh.a ../libs/zbxcommon/libzbxcommon.a -lresolv -lnsl
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestInit'
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestFinal'
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestFinal_ex'
    /usr/lib/libnetsnmp.so: undefined reference to `AES_set_encrypt_key'
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_md5'
    /usr/lib/libnetsnmp.so: undefined reference to `HMAC'
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_MD_CTX_cleanup'
    /usr/lib/libnetsnmp.so: undefined reference to `SSLeay'
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_sha1'
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_MD_CTX_init'
    /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestUpdate'
    /usr/lib/libnetsnmp.so: undefined reference to `RAND_bytes'
    /usr/lib/libnetsnmp.so: undefined reference to `DES_cbc_encrypt'
    /usr/lib/libnetsnmp.so: undefined reference to `DES_ncbc_encrypt'
    /usr/lib/libnetsnmp.so: undefined reference to `DES_key_sched'
    /usr/lib/libnetsnmp.so: undefined reference to `AES_cfb128_encrypt'
    collect2: ld returned 1 exit status
    make[3]: *** [zabbix_server] Error 1
    make[3]: Leaving directory `/home/zabbix/zabbix/src/zabbix_server'
    make[2]: *** [all-recursive] Error 1
    make[2]: Leaving directory `/home/zabbix/zabbix/src/zabbix_server'
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/home/zabbix/zabbix/src'
    make: *** [all-recursive] Error 1
    [zabbix@manager zabbix]$
  • elkor
    Senior Member
    • Jul 2005
    • 299

    #2

    Comment

    • acceleratebiz
      Junior Member
      • Oct 2005
      • 12

      #3
      that link shows somebody missing the openssl-devel libraries, but you can see from my rpms that I have that. Another comment in a thread linked says "it looks like you are missing the crypto libraries. Double check your RPM db and make sure you have installed the devel version of the various crypto libraries."

      What crypto libraries do I need?

      Comment

      • elkor
        Senior Member
        • Jul 2005
        • 299

        #4
        sorry, didn't see your package list up front. All I noticed was the compiler errors, as there have been several posts of late with the exact same chunk of errors, I just linked to one of those posts for consolodation purposes.

        I'm not sure what your problem is... perhaps there is a missing symlink?
        I checked my zabbix_server binary and I'm not linked against anything terribly unusual, although I do have a few krb5 libs that I didn't know I was depended on.

        [root@sentinel]/# ldd /zabbix/bin/zabbix_server
        libmysqlclient.so.14 => /usr/lib/mysql/libmysqlclient.so.14 (0x00cf4000)
        libm.so.6 => /lib/tls/libm.so.6 (0x002c8000)
        libz.so.1 => /usr/lib/libz.so.1 (0x00101000)
        libnetsnmp.so.5 => /usr/lib/libnetsnmp.so.5 (0x00300000)
        libcrypto.so.4 => /lib/libcrypto.so.4 (0x007b9000)
        libresolv.so.2 => /lib/libresolv.so.2 (0x00410000)
        libnsl.so.1 => /lib/libnsl.so.1 (0x006bc000)
        libc.so.6 => /lib/tls/libc.so.6 (0x00197000)
        libcrypt.so.1 => /lib/libcrypt.so.1 (0x00cc4000)
        /lib/ld-linux.so.2 (0x0017e000)
        libgssapi_krb5.so.2 => /usr/lib/libgssapi_krb5.so.2 (0x00111000)
        libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0x00752000)
        libcom_err.so.2 => /lib/libcom_err.so.2 (0x0074d000)
        libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0x00125000)
        libdl.so.2 => /lib/libdl.so.2 (0x002c2000)

        [root@sentinel]/# rpm -q --whatprovides libmysqlclient.so.14
        mysql-4.1.10a-2.RHEL4.1
        [root@sentinel]/# rpm -q --whatprovides libm.so.6
        glibc-2.3.4-2.9
        [root@sentinel]/# rpm -q --whatprovides libz.so.1
        zlib-1.2.1.2-1.2
        [root@sentinel]/# rpm -q --whatprovides libnetsnmp.so.5
        net-snmp-libs-5.1.2-11
        [root@sentinel]/# rpm -q --whatprovides libcrypto.so.4
        openssl-0.9.7a-43.2
        [root@sentinel]/# rpm -q --whatprovides libresolv.so.2
        glibc-2.3.4-2.9
        [root@sentinel]/# rpm -q --whatprovides libnsl.so.1
        glibc-2.3.4-2.9
        [root@sentinel]/# rpm -q --whatprovides libc.so.6
        glibc-2.3.4-2.9
        [root@sentinel]/# rpm -q --whatprovides libcrypt.so.1
        glibc-2.3.4-2.9
        [root@sentinel]/# rpm -q --whatprovides ld-linux.so.2
        glibc-2.3.4-2.9
        [root@sentinel]/# rpm -q --whatprovides libgssapi_krb5.so.2
        krb5-libs-1.3.4-17
        [root@sentinel]/# rpm -q --whatprovides libkrb5.so.3
        krb5-libs-1.3.4-17
        [root@sentinel]/# rpm -q --whatprovides libcom_err.so.2
        e2fsprogs-1.35-12.1.EL4
        [root@sentinel]/# rpm -q --whatprovides libk5crypto.so.3
        krb5-libs-1.3.4-17
        [root@sentinel]/# rpm -q --whatprovides libdl.so.2
        glibc-2.3.4-2.9

        this error is a little odd though as it seems to be libnetsnmp that points to the missing functions. The fact that it exactly mirrors the other people who have had this issue to spite the fact that you seem to have all the ssl libraries is what leads me to believe that they aren't being located for some reason.

        then again, I'm probably wrong. ;-)

        Comment

        • acceleratebiz
          Junior Member
          • Oct 2005
          • 12

          #5
          Thank you elkor for your detailed response. Unfortunately I'm still having trouble . Here are the differences between my libs and yours:

          I have /usr/lib/mysql/libmysqlclient.so.10 instead of /usr/lib/mysql/libmysqlclient.so.14 because my mysql rpm is mysql-3.23.58-16.RHEL3.1. But I don't think this is the problem as the error doesn't look like mysql related.

          I have libm.so.6 and libc.so.6 in /lib instead of /lib/tls. In fact I have no directory called tls inside /lib. again, don't think this is the prob.

          Now the interesting thing is libgssapi_krb5.so.2, libkrb5.so.3 and libk5crypto.so.3 were not in /usr/lib. They were in /usr/kerberos/lib instead. Seeing as they have something to do with encryption, I thought this is the prob. So I created symlinks in /usr/lib, but still no worky .

          The only other differences are I have (due to I'm using centos 3.5):
          openssl-0.9.7a-33.17 instead of openssl-0.9.7a-43.2
          glibc-2.3.2-95.33 instead of glibc-2.3.4-2.9
          zlib-1.1.4-8.1 instead of zlib-1.2.1.2-1.2
          net-snmp-libs-5.0.9-2.30E.19 instead of net-snmp-libs-5.1.2-11
          krb5-libs-1.2.7-47 instead of krb5-libs-1.3.4-17
          e2fsprogs-1.32-15.1 instead of e2fsprogs-1.35-12.1.EL4

          Comment

          • acceleratebiz
            Junior Member
            • Oct 2005
            • 12

            #6
            Can anyone help? I'd really like to use zabbix... but just can't get it to simply compile

            Comment

            • elkor
              Senior Member
              • Jul 2005
              • 299

              #7
              well, I know it doesen't help but obviously SOMETHING is missing. without more data it's hard for me to say. This is one of those problems that you really need to just poke around and fiddle with IMO.
              If you could get me a login capable of running the compiles I'd be happy to poke around as (and if) time permits, perhaps it's something obvious and another set of eyes could help. Other than that, I don't have the environment to replicate your problem and frankly I'm at a dead end with clever ideas.

              you could also try a pre-compiled version.. maybe running an ldd against it will point something out?

              Comment

              • James Wells
                Senior Member
                • Jun 2005
                • 664

                #8
                Greetings,

                Right off the bat, it appears that your netsnmp is compiled with openSSL support built in, however you are not telling it to link the openSSL lib, so the netsnmp is missing the library entries. Please try to compile it manually but add -lssl at the end of the command line. I suspect it will compile correctly.
                Unofficial Zabbix Developer

                Comment

                • nstevens
                  Junior Member
                  • Jun 2006
                  • 2

                  #9
                  Suse 9.0 Enterprise Zabbix 1.1

                  ./configure --with-mysql --with-net-snmp --enable-agent --enable-server

                  I get the same error message. And am a bit of a newbe.
                  Do you mean recompile netsnmp with -lssl? or recompile zabbix?

                  *********************************************
                  make[3]: Entering directory `/usr/src/zabbix-1.1/src/zabbix_server'
                  gcc -g -O2 -o zabbix_server -L/usr/lib/mysql -L/usr/lib evalfunc.o expression.o actions.o zlog.o functions.o server.o ../libs/zbxsysinfo/libzbxsysinfo.a ../libs/zbxsysinfo/linux/libzbxsysinfo2.a ../libs/zbxlog/libzbxlog.a ../libs/zbxpid/libzbxpid.a ../libs/zbxconf/libzbxconf.a ../libs/zbxcrypto/libzbxcrypto.a ../libs/zbxnet/libzbxnet.a pinger/libzbxpinger.a poller/libzbxpoller.a housekeeper/libzbxhousekeeper.a alerter/libzbxalerter.a timer/libzbxtimer.a trapper/libzbxtrapper.a ../libs/zbxemail/libzbxemail.a ../libs/zbxsms/libzbxsms.a ../libs/zbxdbhigh/libzbxdbhigh.a ../libs/zbxcommon/libzbxcommon.a -lmysqlclient -lm -lnetsnmp -lresolv -lnsl
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestInit'
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestFinal'
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestFinal_ex'
                  /usr/lib/libnetsnmp.so: undefined reference to `AES_set_encrypt_key'
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_md5'
                  /usr/lib/libnetsnmp.so: undefined reference to `HMAC'
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_MD_CTX_cleanup'
                  /usr/lib/libnetsnmp.so: undefined reference to `SSLeay'
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_sha1'
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_MD_CTX_init'
                  /usr/lib/libnetsnmp.so: undefined reference to `EVP_DigestUpdate'
                  /usr/lib/libnetsnmp.so: undefined reference to `RAND_bytes'
                  /usr/lib/libnetsnmp.so: undefined reference to `DES_cbc_encrypt'
                  /usr/lib/libnetsnmp.so: undefined reference to `DES_ncbc_encrypt'
                  /usr/lib/libnetsnmp.so: undefined reference to `DES_key_sched'
                  /usr/lib/libnetsnmp.so: undefined reference to `AES_cfb128_encrypt'
                  collect2: ld returned 1 exit status
                  make[3]: *** [zabbix_server] Error 1
                  make[3]: Leaving directory `/usr/src/zabbix-1.1/src/zabbix_server'
                  make[2]: *** [install-recursive] Error 1
                  make[2]: Leaving directory `/usr/src/zabbix-1.1/src/zabbix_server'
                  make[1]: *** [install-recursive] Error 1
                  make[1]: Leaving directory `/usr/src/zabbix-1.1/src'
                  make: *** [install-recursive] Error 1

                  Comment

                  Working...