Page 1 of 2

Problems when configuring and compiling ndoutils on CentOs 6

Posted: Thu Jan 16, 2014 2:42 pm
by bkfrvn
Hi all,

I had problems when configuring and compiling ndoutils on CentOs 6.3 64 bit (CactiEZ 0.7).
I tried with ndotils verions 1.47b and 1.52, 1.52, the problems was the same.

The config.log shows errors:
conftest.c:10:28: error: ac_nonexistent.h: No such file or directory
conftest.c:10:28: error: ac_nonexistent.h: No such file or directory
conftest.c:74:20: error: socket.h: No such file or directory
conftest.c:41:20: error: socket.h: No such file or directory
conftest.c:98: error: expected expression before ')' token
conftest.c:98: error: expected expression before ')' token
conftest.c:98: error: expected expression before ')' token
conftest.c:68: error: void value not ignored as it ought to be
conftest.c:103: error: expected expression before ')' token
conftest.c:103: error: expected expression before ')' token
conftest.c:103: error: expected expression before ')' token
| /* Override any GCC internal prototype to avoid an error.
while the compiling with make produced errors too. Please find the attachment file the config.log and compiling log.

Can any one help me? Thank you very much in advance!

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Fri Jan 17, 2014 11:45 am
by sreinhardt
From your logs, it looks like you are missing glibc-headers, and specifically socket.h, Let's check a few things and verify what might be happening. That conftest.c is specifically used in configure to verify whether everything is there, that is needed. I'm not entirely sure how you got through a proper sane make without socket.h though.

Code: Select all

yum list installed | grep glibc
yum list installed | grep gcc

yum provides */socket.h | grep -i installed
find / -name socket.h

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Sat Jan 18, 2014 9:56 am
by bkfrvn
Dear Spenser,

Thank you very much for your answer!

It seems that both glibc-headers and socket.h have been installed. Please find the results of the commands you mentioned:

[root@cacti ~]# yum list installed | grep glibc
glibc.x86_64 2.12-1.132.el6 @base
glibc-common.x86_64 2.12-1.132.el6 @base
glibc-devel.x86_64 2.12-1.132.el6 @base
glibc-headers.x86_64 2.12-1.132.el6 @base

[root@cacti ~]# yum list installed | grep gcc
gcc.x86_64 4.4.7-4.el6 @base
gcc-c++.x86_64 4.4.7-4.el6 @base
libgcc.x86_64 4.4.7-4.el6 @base

[root@cacti ~]# yum provides */socket.h | grep -i installed
Repo : installed
Repo : installed

[root@cacti ~]# find / -name socket.h
/usr/include/sys/socket.h
/usr/include/bits/socket.h
/usr/include/asm/socket.h
/usr/include/linux/socket.h
/usr/include/asm-generic/socket.h
/tmp/nagios-plugins-1.4.16/gl/sys/socket.h

I tried to include the socket.h to conftest.c. However, I could not find conftest.c, i.e. find / -name conftest.c gave no answer.

Bests!
Giang.

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Mon Jan 20, 2014 3:28 pm
by slansing
And just to be clear... this is not actually a Nagios server..? You are doing this on a cacti server?

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Mon Jan 20, 2014 10:28 pm
by bkfrvn
I compiled ndoutils on a server which both cacti and nagios is installed.
The

Code: Select all

#make
command shown following error:

In file included from db.c:17:
../include/ndo2db.h:58: error: expected specifier-qualifier-list before ‘MYSQL’

Please refer to following topic for more details:
http://support.nagios.com/forum/viewtop ... 224#p86224

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Tue Jan 21, 2014 4:01 pm
by slansing
Alright, we are going to back up and try this from the start, first, what version of Nagios are you trying to install NDOutils on? We need this so we can make sure to compile the proper one.

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Wed Jan 22, 2014 2:19 am
by bkfrvn
I compiled Nagios version 3.5.0 . Thank you very much!

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Wed Jan 22, 2014 10:32 am
by tmcdonald
bkfrvn wrote:Thank you very much!
Is this a "Thank you very much, it worked!" or a "Thank you very much for helping so far!" sort of thank you?

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Wed Jan 22, 2014 8:42 pm
by bkfrvn
It is a "Thank you very much for helping so far!" :)

Re: Problems when configuring and compiling ndoutils on Cent

Posted: Thu Jan 23, 2014 12:57 pm
by slansing
What version of NDO are you trying to compile, and on what version of Nagios Core? Also, what version of mysql are you running on the system?