Installation Problems

Hi

Wonder if you could point me in the right direction, recently installed Red Hat 6.2 and looking to deploy nagios 2.0b3 to monitor our company’s servers.

I ran the ./configure and looked as though it completed successfully.

but when I go to ‘make all’ the following error occurs

[size=75][root@monitor base]# make all
gcc -g -O2 -DHAVE_CONFIG_H -DNSCORE -c -o broker.o broker.c
In file included from …/include/nebmods.h:32,
from broker.c:34:
…/include/nebmodules.h:78: parse error before lt_ptr' ../include/nebmodules.h:78: warning: no semicolon at end of struct or union ../include/nebmodules.h:79: warning: data definition has no type or storage class ../include/nebmodules.h:89: parse error before}’
…/include/nebmodules.h:89: warning: data definition has no type or storage class
In file included from broker.c:34:
…/include/nebmods.h:51: parse error before *' ../include/nebmods.h:54: parse error before*'
make: *** [broker.o] Error 1
[root@monitor base]#[/size]

I am a total *nix newb and not sure if this error is OS related.

try rechecking the configure output…
If you recently installed RH6.2… isn’t that a bit old?

Luca

Please see below the ./configure output

[size=75][root@monitor nagios-2.0b3]# ./configure --prefix=/usr/local/nagios --with-htmurl=/usr/local/nagios --with-nagios-user=nagios --with-nagios-group=nagios
checking for a BSD compatible install… /usr/bin/install -c
checking host system type… i686-pc-linux-gnu
checking for gcc… gcc
checking whether the C compiler (gcc ) works… yes
checking whether the C compiler (gcc ) is a cross-compiler… no
checking whether we are using GNU C… yes
checking whether gcc accepts -g… yes
checking whether make sets ${MAKE}… yes
checking for strip… /usr/bin/strip
checking how to run the C preprocessor… gcc -E
checking for ANSI C header files… yes
checking whether time.h and sys/time.h may both be included… yes
checking for sys/wait.h that is POSIX.1 compatible… yes
checking for arpa/inet.h… yes
checking for ctype.h… yes
checking for dirent.h… yes
checking for errno.h… yes
checking for fcntl.h… yes
checking for getopt.h… yes
checking for grp.h… yes
checking for limits.h… yes
checking for math.h… yes
checking for netdb.h… yes
checking for netinet/in.h… yes
checking for pthread.h… yes
checking for pthreads.h… no
checking for pwd.h… yes
checking for regex.h… yes
checking for signal.h… yes
checking for socket.h… no
checking for strings.h… yes
checking for string.h… yes
checking for syslog.h… yes
checking for unistd.h… yes
checking for uio.h… no
checking for sys/mman.h… yes
checking for sys/types.h… yes
checking for sys/time.h… yes
checking for sys/resource.h… yes
checking for sys/wait.h… (cached) yes
checking for sys/socket.h… yes
checking for sys/stat.h… yes
checking for sys/timeb.h… yes
checking for sys/un.h… yes
checking for sys/ipc.h… yes
checking for sys/msg.h… yes
checking for sys/poll.h… yes
checking for working const… yes
checking whether struct tm is in sys/time.h or time.h… time.h
checking for tm_zone in struct tm… yes
checking for mode_t… yes
checking for pid_t… yes
checking for size_t… yes
checking return type of signal handlers… void
checking for uid_t in sys/types.h… yes
checking type of array argument to getgroups… gid_t
checking for main in -lnsl… yes
checking for socket in -lsocket… no
checking for initgroups… yes
checking for setenv… yes
checking for strdup… yes
checking for strstr… yes
checking for strtoul… yes
checking for unsetenv… yes
checking for type of socket size… size_t
checking for pthread_create in -lcma… no
checking for pthread_create in -lpthread… yes
checking for library containing nanosleep… none required
checking for mail… /bin/mail
Init script directory: /etc/rc.d/init.d
We’ll use default routines (in xdata/xsddefault.) for status data I/O…
We’ll use default routines (in xdata/xcddefault.
) for comment data I/O…
We’ll use default routines (in xdata/xrddefault.) for retention data I/O…
We’ll use template-based routines (in xdata/xodtemplate.
) for object data I/O…
We’ll use default routines (in xdata/xpddefault.) for performance data I/O…
We’ll use default routines (in xdata/xdddefault.
) for scheduled downtime data I/O…
checking for main in -liconv… no
checking for gdImagePng in -lgd (order 1)… no
checking for gdImagePng in -lgd (order 2)… yes
GD library was found!
checking for ltdl.h… yes
checking for lt_dlinit in -lltdl… yes
checking for extra flags needed to export symbols… -Wl,-export-dynamic
checking for linker flags for loadable modules… -shared
checking for traceroute… no
checking for snprintf… yes
checking for type va_list… yes
checking for perl… /usr/bin/perl
creating ./config.status
creating Makefile
creating subst
creating pkginfo
creating base/Makefile
creating common/Makefile
creating contrib/Makefile
creating cgi/Makefile
creating html/Makefile
creating module/Makefile
creating include/Makefile
creating xdata/Makefile
creating daemon-init
creating html/index.html
creating html/side.html
creating include/config.h
include/config.h is unchanged
creating include/snprintf.h
include/snprintf.h is unchanged
creating include/nagios.h
creating include/cgiutils.h
include/cgiutils.h is unchanged

Creating sample config files in sample-config/ …

*** Configuration summary for nagios 2.0b3 04-03-2005 ***:

General Options:

    Nagios executable:  nagios
    Nagios user/group:  nagios,nagios
   Command user/group:  nagios,nagios
        Embedded Perl:  no
         Event Broker:  yes
    Install ${prefix}:  /usr/local/nagios
            Lock file:  ${prefix}/var/nagios.lock
       Init directory:  /etc/rc.d/init.d
              Host OS:  linux-gnu

Web Interface Options:

             HTML URL:  [localhost/usr/local/nagios/](http://localhost/usr/local/nagios/)
              CGI URL:  [localhost/nagios/cgi-bin/](http://localhost/nagios/cgi-bin/)

Traceroute (used by WAP):

Review the options above for accuracy. If they look okay,
type ‘make all’ to compile the main program and CGIs.[/size]

no further ideas. sorry.

Luca

well an idea is there…
gcc could be too old… if it’s the default RH6.2 one.

Luca

My suggestion is to not use the beta nagios. Unless of course, you want lots of little troubles. If you can install 1.2, and you get bored, then try the beta nagios.