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. Installation on Linux

Installation on Linux

Scheduled Pinned Locked Moved Support
10 Posts 2 Posters 163.6k 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.
  • I
    I
    inadiyat
    wrote on last edited by
    #1

    Hi,

    Now I would like to install on Linux Box (uname -a shows: Linux saivrap2 2.4.21-32.ELsmp #1 SMP Fri Apr 15 21:04:33 EDT 2005 i686 athlon i386 GNU/Linux). I want to install NetXMS server and agent using mysql database.

    I have installed following MySQL modules using rpm -i :

    • MySQL-server-standard-5.0.27-0.rhel4.i386.rpm
    • MySQL-client-standard-5.0.27-0.rhel4.i386.rpm
    • MySQL-devel-standard-5.0.27-0.rhel4.i386.rpm
    • MySQL-shared-standard-5.0.27-0.rhel3.i386.rpm

    But when I run:

    ./configure --with-server --with-mysql --with-agent

    I got this error:

    checking for mysql_init in -lmysqlclient... no
    configure: error: libmysqlclient is requred for MySQL support

    Path to the libmysqlclient already there...

    What am I missing ? Please help...

    Thanks.

    Best regards,
    Adiyat

    1 Reply Last reply
    0
    • A
      A
      Alex Kirhenshtein
      wrote on last edited by
      #2

      Hello.

      You also need to install development packages (MySQL-devel-standard-5.0.27-0.rhel4.rpm).

      1 Reply Last reply
      0
      • I
        I
        inadiyat
        wrote on last edited by
        #3

        Yes, I did... (as I post in my question above)

        But the problem still there....

        Any other idea ?

        Thank you very much in advance...

        Best regards,
        Adiyat

        1 Reply Last reply
        0
        • A
          A
          Alex Kirhenshtein
          wrote on last edited by
          #4

          Sorry, i was inattentive.

          Please show your config.log, lines between:

          configure:4714: checking for mysql_init in -lmysqlclient

          and

          configure:4786: error: libmysqlclient is requred for MySQL support

          1 Reply Last reply
          0
          • I
            I
            inadiyat
            wrote on last edited by
            #5

            Thanks for your quick reply, below is the data you asked for (from config.log):

            configure:4714: checking for mysql_init in -lmysqlclient
            configure:4744: gcc -o conftest -g -O2 -D_POSIX_PTHREAD_SEMANTICS -I/usr/local/include -I/usr/local/include -D_POSIX_PTHREAD_SEMANTICS -fno-rtti -fno-exceptions -I/usr/local/include -I/usr/local/mysql/include -I/usr/include/mysql -I/usr/mysql/include -I/usr/local/include/mysql -I/usr/local/mysql/include/mysql -I/usr/mysql/include/mysql -s -L/usr/local/lib -L/usr/local/mysql/lib -L/usr/lib64/mysql -L/usr/lib/mysql -L/usr/mysql/lib -L/usr/local/lib/mysql -L/usr/local/mysql/lib/mysql -L/usr/mysql/lib/mysql conftest.c -lmysqlclient  -lm  >&5
            /usr/lib/mysql/libmysqlclient.a(my_compress.o)(.text+0x65): In function `my_compress_alloc':
            /home/mysqldev/rpm/BUILD/mysql-5.0.27/libmysql/my_compress.c:58: undefined reference to `compress'
            /usr/lib/mysql/libmysqlclient.a(my_compress.o)(.text+0x178): In function `my_uncompress':
            /home/mysqldev/rpm/BUILD/mysql-5.0.27/libmysql/my_compress.c:85: undefined reference to `uncompress'
            collect2: ld returned 1 exit status
            configure:4750: $? = 1
            configure: failed program was:

            /* confdefs.h.  */
            #define PACKAGE_NAME "NetXMS"
            #define PACKAGE_TARNAME "netxms"
            #define PACKAGE_VERSION "0.2.13"
            #define PACKAGE_STRING "NetXMS 0.2.13"
            #define PACKAGE_BUGREPORT "NetXMS Team [email protected]"
            #define PACKAGE "netxms"
            #define VERSION "0.2.13"
            #ifdef __cplusplus
            extern "C" void std::exit (int) throw (); using std::exit;
            #endif
            #define HAVE_LIBM 1
            #define WITH_MYSQL
            /* end confdefs.h.  */
            /* Override any gcc2 internal prototype to avoid an error.  */
            #ifdef __cplusplus
            extern "C"
            #endif
            /* We use char because int might match the return type of a gcc2
            builtin and then its argument prototype would still apply.  */
            char mysql_init ();
            int
            main ()
            {
            mysql_init ();
            ;
            return 0;
            }

            configure:4776: result: no
            configure:4786: error: libmysqlclient is requred for MySQL support

            Best regards,
            Adiyat

            1 Reply Last reply
            0
            • A
              A
              Alex Kirhenshtein
              wrote on last edited by
              #6

              Looks like zlib is not detected. Try to configure it that way:

              LDFLAGS=-lz ./configure --with-server --with-agent --with-mysql

              If it fails, check, if zlib-devel is installed?

              1 Reply Last reply
              0
              • I
                I
                inadiyat
                wrote on last edited by
                #7

                YES !!!!

                It works now....

                I just need to install zlib-devel-1.1.4-8.7x.i386.rpm (www.zlib.net).

                Thank you very much for your great support.

                Best regards,
                Adiyat

                1 Reply Last reply
                0
                • I
                  I
                  inadiyat
                  wrote on last edited by
                  #8

                  BTW, how do you get to this conclusion ? (Need zlib-devel). I have to learn something from this...

                  Thanks & Best regards,
                  Adiyat

                  1 Reply Last reply
                  0
                  • A
                    A
                    Alex Kirhenshtein
                    wrote on last edited by
                    #9

                    ...
                    /home/mysqldev/rpm/BUILD/mysql-5.0.27/libmysql/my_compress.c:58: undefined reference to `compress'
                    ...
                    /home/mysqldev/rpm/BUILD/mysql-5.0.27/libmysql/my_compress.c:85: undefined reference to `uncompress'
                    ...

                    "undefined reference" means that linker was unable to resolve (=find) functions "compress" and "decompress" in all given libraries - mysql probably use them for client/server protocol compression.

                    Next steps can vary:

                    1. search google: "mysql undefined reference compress uncompress" will take you to the http://dev.mysql.com/doc/refman/5.0/en/link-errors.html, "Problems Linking to the MySQL Client Library" with solution: "If you get undefined reference errors for the uncompress or compress  function, add -lz to the end of your link command and try again."
                    2. grep *.so/*.a files in your /usr/lib (/lib, etc) for missing symbol. You can later check exact library using "nm" tool:

                    alk@ns$ nm libz.a | grep "T compress"
                    000000a4 T compress
                    00000000 T compress2

                    "T" means that this function exist in this exact library.

                    1 Reply Last reply
                    0
                    • I
                      I
                      inadiyat
                      wrote on last edited by
                      #10

                      Again, thank you very much...

                      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