cactid compile error

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

jkstraw
Posts: 34
Joined: Tue Aug 01, 2006 10:24 am
Contact:

cactid compile error

Post by jkstraw »

Hello,

I know this has been discussed in a number of posts in the past but after reading as many posts as I can find I am still unable to resolve the compile issue on my server.

When running the ./configure script I get the well documented:

checking for mysql_init in -lmysqlclient... no
configure: error: MySQL libraries not found.


Here are the details of my environment:

Software:

RHEL ES4 Update 5 - x64
Linux mon_25 2.6.9-55.ELsmp #1 SMP Fri Apr 20 16:36:54 EDT 2007 x86_64 x86_64 x86_64 GNU/Linux
MySQL 4.1.20-2
mysql Ver 14.7 Distrib 4.1.20, for redhat-linux-gnu (x86_64) using readline 4.3
Output of rpm -qa |gep mysql

mysql-devel-4.1.20-2.RHEL4.1
mod_auth_mysql-2.6.1-2.2
mysqlclient10-3.23.58-4.RHEL4.1
libdbi-dbd-mysql-0.6.5-10.RHEL4.1
mysqlclient10-devel-3.23.58-4.RHEL4.1
mysql-4.1.20-2.RHEL4.1
mysql-server-4.1.20-2.RHEL4.1
mysql-4.1.20-2.RHEL4.1
mysqlclient10-3.23.58-4.RHEL4.1
mysql-bench-4.1.20-2.RHEL4.1
freeradius-mysql-1.0.1-3.RHEL4.3
php-mysql-4.3.9-3.22.4

Cacti specific
cacti 0.8.6j
cactid 0.8.6i

Hardware:
HP Proliant DL385 G2
2 x Opteron 2.8Gz
8 GB Ram


I have reviewed the following posts:

http://forums.cacti.net/viewtopic.php?t ... sc&start=0

http://forums.cacti.net/viewtopic.php?t ... ries+found

http://forums.cacti.net/viewtopic.php?t ... ries+found

http://forums.cacti.net/viewtopic.php?t ... ries+found

After trying a few of the suggestion in these posts I am still unable to get past this error. The topic started by another x64 RHEL user indicates some edits to the ./configure script fixed his problems - however when reviewing the ./configure script it looks like there are substantial changes.

Can anyone lend a hand with this? I am really stumped. :-?
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

I will direct theWitness to this thread to help you out.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Can you please download the configure.ac file from SVN BRANCH_0_8_6 and then run the following:

autoconf
./configure

Thanks,

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
jkstraw
Posts: 34
Joined: Tue Aug 01, 2006 10:24 am
Contact:

Post by jkstraw »

Hello,

I have followed your instructions to the best of my abilities and received the same error.

Attached is a snip from the session so you can see exactly what I did.

If I can provide you with any additional information please let me know.

Thank you very much for the quick reply - greatly appreciated!
Attachments
cactid_1.txt
(6.54 KiB) Downloaded 191 times
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

do the following:

su -
updatedb
locate mysqlclient_r

Let me know what you find.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
jkstraw
Posts: 34
Joined: Tue Aug 01, 2006 10:24 am
Contact:

Post by jkstraw »

Hi,

Thanks again for the help - I really appreciate it.

Here are the results:

[root@mon_25 ~]# updatedb
[root@mon_25 ~]# locate mysqlclient_r

/usr/lib/mysql/libmysqlclient_r.so.10.0.0
/usr/lib/mysql/libmysqlclient_r.so.10
/usr/lib/mysql/libmysqlclient_r.so.14.0.0
/usr/lib/mysql/libmysqlclient_r.so.14
/usr/lib64/mysql/libmysqlclient_r.so
/usr/lib64/mysql/libmysqlclient_r.so.10.0.0
/usr/lib64/mysql/libmysqlclient_r.so.10
/usr/lib64/mysql/libmysqlclient_r.so.14.0.0
/usr/lib64/mysql/libmysqlclient_r.a
/usr/lib64/mysql/libmysqlclient_r.so.14
/usr/lib64/mysql3/mysql/libmysqlclient_r.so
/usr/lib64/mysql3/mysql/libmysqlclient_r.so.10.0.0
/usr/lib64/mysql3/mysql/libmysqlclient_r.so.10
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Post your config.log file.

Thanks,

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
jkstraw
Posts: 34
Joined: Tue Aug 01, 2006 10:24 am
Contact:

Post by jkstraw »

Thanks again TheWitness

Attached is the config.log
Attachments
config_log.txt
(32.38 KiB) Downloaded 193 times
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Well, this is interesting, your locate indicated that libmysqlclient_r was found in /usr/lib/mysql. However, when performing the conftest.c compile, it was not able to locate it in the location specified by "-L /usr/lib/mysql". Take a look at this from config.log:

Code: Select all

configure:5434: checking for mysql_init in -lmysqlclient_r
configure:5464: gcc -o conftest -I/usr/include/mysql -g -O2  -L/usr/lib/mysql  conftest.c -lmysqlclient_r  -lcrypto -lz -lpthread -lm -lnsl  >&5
/usr/bin/ld: cannot find -lmysqlclient_r
collect2: ld returned 1 exit status
configure:5470: $? = 1
configure: failed program was:
| /* confdefs.h.  */
TheWitness

I will look at the configure.ac file again for something "reasonable".
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
faxe
Posts: 1
Joined: Fri Jul 06, 2007 3:57 am

Post by faxe »

Hi,

I think i had the same problem i got rid of the entries in the configure for the lib directory and just look for lib64 and then everything was working fine for me.

lg

faxe
jkstraw
Posts: 34
Joined: Tue Aug 01, 2006 10:24 am
Contact:

Post by jkstraw »

Thank you for replying - greatly appreciated!

It looks like your solution worked - I was able to run the ./configure script without errors and the "make" created the cactid and cactid.conf files.

I copied the two files to /usr/local but since updating the poller in the cacti poller settings I am no longer seeing updates to my graphs. I have put logging into debug mode but nothing has been written to the cacti.log file.

Any thoughts?
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Run Cactid in "MEDIUM" mode from the command line. I bet you are hosed from a shared library perspective. Also, run the following from the cactid binary directory.

ldd ./cactid

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
jkstraw
Posts: 34
Joined: Tue Aug 01, 2006 10:24 am
Contact:

Post by jkstraw »

Here are the results:

Code: Select all

root# ./cactid --verbosity=MEDIUM --conf=/usr/local/cactid.conf
CACTID: Using cactid config file [/usr/local/cactid.conf]
CACTID:
and here are the results of the ldd command:

Code: Select all

root# ldd ./cactid
        libnetsnmp.so.5 => /usr/lib64/libnetsnmp.so.5 (0x00000039a0700000)
        libmysqlclient.so.14 => /usr/lib64/mysql/libmysqlclient.so.14 (0x000000399e300000)
        libcrypto.so.4 => /lib64/libcrypto.so.4 (0x00000039a0f00000)
        libz.so.1 => /usr/lib64/libz.so.1 (0x000000399d400000)
        libpthread.so.0 => /lib64/tls/libpthread.so.0 (0x000000399df00000)
        libm.so.6 => /lib64/tls/libm.so.6 (0x000000399d900000)
        libnsl.so.1 => /lib64/libnsl.so.1 (0x00000039a3100000)
        libc.so.6 => /lib64/tls/libc.so.6 (0x000000399d600000)
        libcrypt.so.1 => /lib64/libcrypt.so.1 (0x00000039a2d00000)
        libssl.so.4 => /lib64/libssl.so.4 (0x00000039a2b00000)
        libgssapi_krb5.so.2 => /usr/lib64/libgssapi_krb5.so.2 (0x00000039a1200000)
        libkrb5.so.3 => /usr/lib64/libkrb5.so.3 (0x00000039a0900000)
        libcom_err.so.2 => /lib64/libcom_err.so.2 (0x00000039a0500000)
        libk5crypto.so.3 => /usr/lib64/libk5crypto.so.3 (0x00000039a0b00000)
        libresolv.so.2 => /lib64/libresolv.so.2 (0x000000399e900000)
        libdl.so.2 => /lib64/libdl.so.2 (0x000000399db00000)
        /lib64/ld-linux-x86-64.so.2 (0x000000399d200000)
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Download the SVN version BRANCH_0_8_6 and then try this again. You will likely have to hack the configure.ac file as you did before.

Then, you will be a more informative error. It is likely that you have the MySQL v4 Client API libraries, or even something older, and do not have access to the database, or you simply have not setup your cactid.conf file properly, or you may need to enable OLD_PASSWORD support.

Google it (aka "OLD_PASSWORD site:forums.cacti.net") if when you recompile, you get an database access violation.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
jkstraw
Posts: 34
Joined: Tue Aug 01, 2006 10:24 am
Contact:

Post by jkstraw »

Sorry - I am going to have to ask a simple question - I have the BRANCH_0_8_6 downloaded - it does not come with a "configure" script. Only the configure.ac - how can I compile
Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests