Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (Flatly)
  • No Skin
Collapse
Brand Logo

NetXMS Forum

  1. Home
  2. Support
  3. v.1.2.2 Static Agent Build with ODBC fails

v.1.2.2 Static Agent Build with ODBC fails

Scheduled Pinned Locked Moved Support
5 Posts 2 Posters 35.0k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • X
    X
    xatteg
    wrote on last edited by
    #1

    Hello Victor,

    I've got a problem compiling Static Agent when enabling ODBC subagent.
    Configure string:
    ./configure --with-static-agent --disable-encryption --with-static-subagents=ODBCQuery --without-sqlite --with-all-static

    Error:
    make[4]: Entering directory `/distr/netxms-1.2.2/src/agent/core'
      CXXLD  nxagentd
    static_subagents.o: In function `InitStaticSubagents()':
    /distr/netxms-1.2.2/src/agent/core/static_subagents.cpp:13: undefined reference to `NxSubAgentRegister_ODBCQUERY'
    collect2: ld returned 1 exit status
    make[4]: *** [nxagentd] Error 1
    make[4]: Leaving directory `/distr/netxms-1.2.2/src/agent/core'
    make[3]: *** [all-recursive] Error 1
    make[3]: Leaving directory `/distr/netxms-1.2.2/src/agent'
    make[2]: *** [all-recursive] Error 1
    make[2]: Leaving directory `/distr/netxms-1.2.2/src'
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/distr/netxms-1.2.2'
    make: *** [all] Error 2
    [root@netxms netxms-1.2.2]#

    Static agent without ODBC subagent compiles fine and Not static agent with ODBC subagent also compiles fine.

    1 Reply Last reply
    0
    • V
      V
      Victor Kirhenshtein
      wrote on last edited by
      #2

      Hi!

      Try to use

      --with-static-subagents=odbcquery

      (with all small letters).

      Best regards,
      Victor

      1 Reply Last reply
      0
      • X
        X
        xatteg
        wrote on last edited by
        #3

        This does not help, same error appears.

        1 Reply Last reply
        0
        • V
          V
          Victor Kirhenshtein
          wrote on last edited by
          #4

          I have fixed this error. Agent compiles both with and without all-static flag. I'm not sure if it will work correctly with ODBC and all-static, because ODBC uses dynamic linking internally to load drivers, but you can check. Agent compiled without all-static should work without problem, but it will depend on system shared libraries - only NetXMS libraries and subagents will be included into nxagentd binary. Updated source package can be downloaded from here: https://netxms.org/download/patches/014/netxms-1.2.2.tar.gz.

          Best regards,
          Victor

          1 Reply Last reply
          0
          • X
            X
            xatteg
            wrote on last edited by
            #5

            Hello Victor,

            It is working now! It compiled in both cases with and without --with-all-static (I'm using without). The thing is it was trying to copy odbc.so to <netxms-install-dir>/odbc.ddr when I issued "make install". So I had to go to "src/agent" subdir and issue "make install" there, and everything installed fine.

            1 Reply Last reply
            0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            Powered by NodeBB Contributors
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups