Ad Widget

Collapse

Trying to compile zabbix agent on QNAP TS-119P+ (Marvell Orion / ARM)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • -bk-
    Junior Member
    • Aug 2010
    • 21

    #1

    Trying to compile zabbix agent on QNAP TS-119P+ (Marvell Orion / ARM)

    I am trying to compile zabbix agent 1.8.4 - 1.8.7 on a QNAP TS-119P+ NAS system, which is powered by a Marvell ARM CPU. Unfortunately, it just aborts with following error message:

    Code:
    [/share/HDA_DATA/compile/zabbix-1.8.4] # ./configure --enable-agent --prefix=/opt/zabbix
    Code:
    ./configure: line 14052: syntax error near unexpected token `('
    ./configure: line 14052: ` for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do'
    Haven't tried this on a x86 based NAS yet, but does anyone have a clue?

    Code:
    Using built-in specs.
    Target: arm-none-linux-gnueabi
    Configured with: ../gcc-4.2/configure --build=i386-pc-linux-gnu --host=arm-none-linux-gnueabi --target=arm-none-linux-gnueabi --prefix=/opt --disable-nls --disable-static --with-as=/home/slug/optware/cs08q1armel/toolchain/arm-2008q1/bin/arm-none-linux-gnueabi-as --with-ld=/home/slug/optware/cs08q1armel/toolchain/arm-2008q1/bin/arm-none-linux-gnueabi-ld --enable-languages=c,c++ --disable-multilib --enable-threads --disable-libmudflap --disable-libssp --disable-libgomp --disable-libstdcxx-pch --enable-shared --enable-symvers=gnu --enable-__cxa_atexit
    Thread model: posix
    gcc version 4.2.3
    Last edited by -bk-; 23-09-2011, 14:46. Reason: Got it, finally, and will contribute binaries
  • frater
    Senior Member
    • Oct 2010
    • 340

    #2
    I haven't compiled zabbix myself for DD-WRT and Freetz, but on both platforms they were having problems with versions > 1.6

    On Freetz it's 1.4 and on DD-WRT it's 1.6

    You will probably have more success with one of these versions.
    Please post it if you are successful.

    I have a few QNAPs in my management portfolio.

    BTW: that error message is probably a syntax-error in that shell-script (for that specific shell, busybox??). Maybe you can have bash on it and you can run it with 'bash ./configure'
    Last edited by frater; 12-09-2011, 17:08.
    Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP

    Comment

    • -bk-
      Junior Member
      • Aug 2010
      • 21

      #3
      Great hint, thanks. You are right, that must be a busybox issue, will try that as soon as I am at the office!

      Comment

      • -bk-
        Junior Member
        • Aug 2010
        • 21

        #4
        Unfortunately, also if I execute this in bash, the configure still aborts at exactly the same line, it must be something OS specific (QNAP uses uLinux, a debian derivate...)

        Comment

        • -bk-
          Junior Member
          • Aug 2010
          • 21

          #5
          frater, just tried to compile 1.6.8, but configure is also aborting at the same point (other line, but same function in the configure script). I tried it in bash an in busybox, exactly the same error. It must be something related to uLinux then...
          Gonna try it on a x86 NAS later, but I don't think I will be successful, as it is the same OS, just Intel Atom based instead of Marvell Orion (ARM)

          There is a how-to regarding successful compilation of zabbix agent on an ARM based Synology NAS here:



          It is a similar OS, so it should work out on QNAP anyhow...

          Comment

          • -bk-
            Junior Member
            • Aug 2010
            • 21

            #6
            I was able to compile zabbix agent 1.1.7 now, that was the newest working. Everything newer would not even configure.

            Now lets try if it works with 1.8.5 server :-)

            Comment

            • -bk-
              Junior Member
              • Aug 2010
              • 21

              #7
              Contribution: zabbix_agent zabbix_get and zabbix_sender for armv5tel

              Got them compiled with statically linked libraries, so they should run on any armv5tel linux with kernel 2.6

              I will use them on my QNAP NAS system, but they should work on Synology, Netgear and so on.

              Get your copy at



              This is my way to thank the community for all support you gave!
              I compiled 1.8.4, but will try to compile all newer releases and keep a little repository!

              Comment

              • frater
                Senior Member
                • Oct 2010
                • 340

                #8
                I just tried to install them, but my Qnaps have Intel processors

                Thanks anyway
                Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP

                Comment

                • -bk-
                  Junior Member
                  • Aug 2010
                  • 21

                  #9
                  then use the generic x86 precompiled binaries for Kernel 2.6, they work (on a TS-459P+ at least...)
                  http://www.zabbix.com/downloads/1.8....23.i386.tar.gz

                  Comment

                  • frater
                    Senior Member
                    • Oct 2010
                    • 340

                    #10
                    Yes...
                    That one is working...
                    Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP

                    Comment

                    • frater
                      Senior Member
                      • Oct 2010
                      • 340

                      #11
                      I created a startup script in /etc/init.d/ and symbolic links in both /etc/rcS.d/ and /etc/rcK.d/ with a config in /etc/zabbix/
                      The binaries are in /bin and /sbin...

                      It all works, but everything's gone after a restart.....

                      Is there an easy way to make these stick?
                      I thought I was writing to harddisk, but apparently it was all some kind of copy to /tmp...
                      I didn't have time to examine the way the system is booting.
                      Can you be of any help?

                      I solved all this.....
                      Will come back later with a howto
                      Last edited by frater; 27-09-2011, 19:04.
                      Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP

                      Comment

                      • frater
                        Senior Member
                        • Oct 2010
                        • 340

                        #12
                        I ran into a Qnap with an ARM-processor and therefore tried your binaries.
                        You don't have a zabbix_agentd, but a zabbix_agent.

                        I believe they need inetd or xinetd, don't they?
                        Weren't you able to compile the daemon that can listen itself?

                        I will try to get it to run with inetd.....

                        edit: There's no inetd on my system... I don't want to run optware as I have it all setup now with autostart and all.
                        I only need the inetd binary.
                        But I would rather have the zabbix_agentd
                        Last edited by frater; 27-09-2011, 19:46.
                        Zabbix agents on Linux, FreeBSD, Windows, AVM-Fritz!box, DD-WRT and QNAP

                        Comment

                        • zordesu
                          Junior Member
                          • Jul 2012
                          • 1

                          #13
                          My environment is TS879URP-24 and firm is TS-879U_3.6.1_Build0302.

                          I can monitor the QNAP system.

                          Please use these files(Readme.txt, Configure.Patch,build.sh) and you had better save under the /share/MD0_DATA/Zabbix. Because if you save the data on VRAM and reboot, these file will be gone.

                          ########Readme.txt########
                          --- Files ---
                          readme.txt ... this file
                          configure.patch ... patch file
                          build.sh ... compile script

                          --- Directory Structure ---
                          (somewhere)/readme.txt
                          (somewhere)/configure.patch
                          (somewhere)/build.sh
                          (somewhere)/zabbix-2.0.1.tar.gz

                          --- Install Required Packages ---
                          # ipkg install gcc
                          # ipkg install grep
                          # ipkg install make
                          # ipkg install sed
                          # ipkg install patch

                          --- How to compile zabbix on QNAP ---
                          # chmod 755 build.sh
                          # tar zxvf zabbix-2.0.1.tar.gz
                          # cd zabbix-2.0.1
                          # patch configure < ../configure.patch
                          # ../build.sh

                          --- How to execute zabbix_agentd ---
                          # cp -rfp /share/MD0_DATA/Zabbix/install/zabbix-2.0.1/dist/opt/zabbix /opt/
                          # /opt/zabbix/sbin/zabbix_agentd -c /opt/zabbix/etc/zabbix_agentd.conf

                          --- How to kill zabbix_agentd ---
                          # killall zabbix_agentd

                          --- END ---

                          ########Configure.Patch########

                          10542a10543,10546
                          > elif test -f /opt/include/iconv.h; then
                          > ICONV_CFLAGS="-I/opt/include"
                          > ICONV_LDFLAGS="-L/opt/lib"
                          > found_iconv="yes"


                          ########build.sh########
                          #!/opt/bin/bash

                          export PATH=/opt/bin:$PATH

                          /opt/bin/bash ./configure --enable-agent --prefix=/opt/zabbix
                          make
                          make install DESTDIR=`pwd`/dist

                          Comment

                          Working...