Ad Widget

Collapse

Building Zabbix 1.1 in a Red Hat EL 3 environment

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • geller1a
    Junior Member
    • Jun 2006
    • 3

    #1

    Building Zabbix 1.1 in a Red Hat EL 3 environment

    Unfortunately it is not possible to build Zabbix 1.1 binaries from scratch in a Red Hat Enterprice Linux 3 environment (gcc 3.2.3-42, glibc 3.2.3).

    It tried to create binaries for agent and server using
    ./configure --enable-static --with-mysql --enable-server --enable-agent

    but I received:
    make[3]: Entering directory `/home/guiadmin/zabbix-1.1/src/zabbix_agent'
    if gcc -DHAVE_CONFIG_H -I. -I. -I../../include -static -g -O2 -MT zabbix_agent.o -MD -MP -MF ".deps/zabbix_agent.Tpo" -c -o zabbix_agent.o zabbix_agent.c; \
    then mv -f ".deps/zabbix_agent.Tpo" ".deps/zabbix_agent.Po"; else rm -f ".deps/zabbix_agent.Tpo"; exit 1; fi
    gcc -static -g -O2 -o zabbix_agent zabbix_agent.o ../libs/zbxsysinfo/libzbxsysinfo.a ../libs/zbxsysinfo/linux/libzbxsysinfo2.a ../libs/zbxlog/libzbxlog.a ../libs/zbxcrypto/libzbxcrypto.a ../libs/zbxnet/libzbxnet.a ../libs/zbxconf/libzbxconf.a ../libs/zbxcommon/libzbxcommon.a
    ../libs/zbxsysinfo/linux/libzbxsysinfo2.a(proc.o)(.text+0x846): In function `PROC_MEMORY':
    /home/guiadmin/zabbix-1.1/src/libs/zbxsysinfo/linux/proc.c:83: Using 'getpwnam' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
    ../libs/zbxsysinfo/libzbxsysinfo.a(common.o)(.text+0x1cc4): In function `forward_request':
    common/common.c:1391: Using 'gethostbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
    ../libs/zbxsysinfo/libzbxsysinfo.a(common.o)(.text+0x2ca1): In function `CHECK_DNS':
    common/common.c:2023: undefined reference to `__res_query'
    collect2: ld returned 1 exit status
    make[3]: *** [zabbix_agent] Error 1
    make[3]: Leaving directory `/home/guiadmin/zabbix-1.1/src/zabbix_agent'


    Unfortunately the resolver-methods are included in libresolv, instead of glibc. Furthermore the -static flag causes problems with glibc. To solve these problems, I added two addition flags to the make command:
    make CFLAGS="-g -O2" LDFLAGS=-lresolv

    Maybe this helps somebody to build Zabbix 1.1 on RH EL3.
    Best regards
    Axel
  • vrtareg
    Senior Member
    • May 2006
    • 293

    #2
    Hi

    I have problems with configuring and compiling on RHEL 3 WS.
    Try to change PATH variable before configure and compile.
    I set it to:

    export PATH=/sbin:/bin:/usr/sbin:/usr/bin

    After this all process is going Ok.

    Regards
    Areg

    Comment

    Working...