Ad Widget

Collapse

AIX 5.3 PPC Agent Compilation Errors

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Thomas Williams
    Junior Member
    • Feb 2007
    • 7

    #1

    AIX 5.3 PPC Agent Compilation Errors

    Hello,

    I'm getting errors when trying to compile the latest version of the agent on an AIX 5.3 PPC machine. I'd appreciate any insight. Thanks!

    # ./configure --enable agent
    checking build system type... powerpc-ibm-aix5.3.0.0
    checking host system type... powerpc-ibm-aix5.3.0.0
    checking for gcc... /opt/gcc-4.1.1/bin/gcc
    ...
    Configuration:

    Detected OS: aix5.3.0.0
    Install path: /usr/local
    Compilation arch: aix

    Compiler: /opt/gcc-4.1.1/bin/gcc
    Compiler flags: -g -O2
    Linker flags:
    Libraries: -lnsl

    Enable server: no
    With database: no

    Enable agent: yes

    # make
    ...
    /opt/gcc-4.1.1/bin/gcc -g -O2 -o zabbix_agentd zabbix_agentd-active.o zabbix_agentd-stats.o zabbix_agentd-cpustat.o zabbix_agentd-diskdevices.o zabbix_agentd-interfaces.o zabbix_agentd-logfiles.o zabbix_agentd-zabbix_agentd.o zabbix_agentd-zbxconf.o zabbix_agentd-listener.o zabbix_agentd-eventlog.o ../../src/libs/zbxsysinfo/libzbxagentsysinfo.a ../../src/libs/zbxsysinfo/aix/libspecsysinfo.a ../../src/libs/zbxsysinfo/common/libcommonsysinfo.a ../../src/libs/zbxsysinfo/simple/libsimplesysinfo.a ../../src/libs/zbxlog/libzbxlog.a ../../src/libs/zbxsys/libzbxsys.a ../../src/libs/zbxnix/libzbxnix.a ../../src/libs/zbxcomms/libzbxcomms.a ../../src/libs/zbxconf/libzbxconf.a ../../src/libs/zbxcommon/libzbxcommon.a ../../src/libs/zbxcrypto/libzbxcrypto.a -lnsl
    ld: 0711-317 ERROR: Undefined symbol: .flock
    ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
    collect2: ld returned 8 exit status
    make[2]: *** [zabbix_agentd] Error 1
    make[2]: Leaving directory `/tmp/zabbix-1.3.6/src/zabbix_agent'
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/tmp/zabbix-1.3.6/src'
    make: *** [all-recursive] Error 1
  • NOB
    Senior Member
    Zabbix Certified Specialist
    • Mar 2007
    • 469

    #2
    Hi,

    oh what a wonder AIX always is

    Instead of not finding flock.h it - as it is done on Solaris,
    it obviously finds it !
    But the library including the flock function is not found.
    The missing function flock is in /lib/libbsd.a according to IBM and my researches (IBM AIX 5.3 on PPC).
    So, you should include /lib/libbsd.a in the LDFLAGS.
    or use my patch . I guess it works on AIX as well as on Solaris and
    should not result in any compilation / linking errors. This is because the
    lockf function used in my patch is in the standard libc.a (again
    according to the same IBM online page).

    Edited: You will have to change the "EAGAIN" in my patch to "EACCESS"
    to get it really working on AIX. This is mentioned on the online
    IBM web page at the end and I didn't read up to there until just now !

    BTW: I am very interested in a compiled agent for this platform !
    We have some of those systems (real large ones) around, but there
    is no compiler installed and those are production systems I don't want to change.

    HTH,

    Norbert.
    Last edited by NOB; 07-05-2007, 08:14.

    Comment

    • Thomas Williams
      Junior Member
      • Feb 2007
      • 7

      #3
      Norbert,

      Thanks for the advice. After patching pid.c with your patch, it appears to compile successfully. However, when I execute zabbix_agentd, it hangs and uses all available CPU cycles. I've seen similar behavior when compiling for S390. Do you know of a way to get more detailed debug information or do you have any idea what might be happening?

      Thanks,

      -Thomas

      Comment

      • NOB
        Senior Member
        Zabbix Certified Specialist
        • Mar 2007
        • 469

        #4
        Hi,

        try setting the "DebugLevel=5" and increase the size of the logfile
        by setting "LogFileSize=50", both in the zabbix_agentd.conf file.

        You'll get more info in the logfile /tmp/zabbix_agentd.log

        I hope this is not introduced by my patch

        HTH,

        Norbert.

        Comment

        • Alexei
          Founder, CEO
          Zabbix Certified Trainer
          Zabbix Certified SpecialistZabbix Certified Professional
          • Sep 2004
          • 5654

          #5
          We fixed compilation under AIX. It was tested under 5.2.
          Alexei Vladishev
          Creator of Zabbix, Product manager
          New York | Tokyo | Riga
          My Twitter

          Comment

          • Thomas Williams
            Junior Member
            • Feb 2007
            • 7

            #6
            Excellent! Are the fixes in v1.3.8 or will I need to get the trunk?

            Comment

            • Alexei
              Founder, CEO
              Zabbix Certified Trainer
              Zabbix Certified SpecialistZabbix Certified Professional
              • Sep 2004
              • 5654

              #7
              These fixes are in the trunk only.
              Alexei Vladishev
              Creator of Zabbix, Product manager
              New York | Tokyo | Riga
              My Twitter

              Comment

              Working...