[Nagios-users] Cannot use swapctl in the large files compilation environment on 23bit Solaris 10

2008-09-15 Thread Henti Smith
Good day, 

I'm testing nagios from my 32bit solaris test machine and I cannot get
check_swap compiled. The config.log for ./configure --prefix=/opt/nagios
is as follows : 

In file included from conftest.c:89:
/usr/include/sys/swap.h:50:2: #error Cannot use swapctl in the large
files compilation environment

I've looked around n the net and there seems to have been issues before
and code changes were made to fix this and seems to have been tested on
solaris 9 according to the entry in Changelog. 

Does anybody have an idea how to fix this ? 

--
Henti Smith
Private Bank IT - Lending

Investec Private Bank
Telephone: (2711) 286 7735
100 Grayston Drive, Sandown, Sandton, 2196, South Africa
PO Box 785700, Sandton, 2146, South Africa
www.investecprivatebank.co.za 
An authorised financial services provider

Please consider the environment before printing this e-mail


http://www.investec.com/EmailDisclaimer/emaildisclaimer.htm

The disclaimer also provides our corporate information and names of our 
directors as required by law.

The disclaimer is deemed to form part of this message in terms of Section 11 of 
the Electronic Communications and Transactions Act 25 of 2002. 
If you cannot access the disclaimer, please obtain a copy thereof from us by 
sending an email to: [EMAIL PROTECTED]

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


[Nagios-users] Really slow log2ndo

2008-09-15 Thread Benjamin Krein
Am I the only one who is experiencing very slow performance importing  
archived log files into MySQL with log2ndo?  I'm averaging ~1.5 log  
entries per second being inserted.  This seems slow to me.

I've tried dividing the parsing  MySQL service across 2 servers as  
well as move all the parsing/inserting locally on a remote (to Nagios)  
server which is much beefier than our actual Nagios server.  My  
insertion speed remains fairly consistent.

I'm currently using the Unix socket option.  Is this the wrong one?   
Would TCP be faster (doesn't seem so)?  Should I process the logs to  
flat text files first then push those to ndo2db?

At this rate it's going to take FOREVER!  I have ~10 million archived  
lines to parse and insert.  Maybe I'm expecting too much?

Benjamin Krein
Systems Administrator
AWeber Communications, Inc.




-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


[Nagios-users] Nagios configuraion best practice

2008-09-15 Thread Kenneth Holter
Hello all,


I'm new to Nagios, and are planning on using Nagios for monitoring our
network of Linux servers.

Are there any best practice documents on how to manage the different
definitions such as hostgroups, services, servicegroups, and so forth in an
enterprise environment?


Regards,
Kenneth Holter
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null

Re: [Nagios-users] check_procs from Nagios plugins 1.4.12 is veeery slow on Solaris 10 5/08

2008-09-15 Thread Bernd Nies
Duncan Ferguson wrote:
 Can you please try a recent snapshot?  The I rewrote the pst3 binary to 
 enable to work faster and be zone aware (to allow use in in the global 
 and sub zones).  Its been fine for me, but I don't think there has been 
 a release since the code was committed.
 
 CC'ing in the nagiosplug-devel list (probably best place for this thread).

Hmmm ... I took the 15 September snapshot at 
http://nagiosplug.sourceforge.net/snapshot/


[EMAIL PROTECTED] ~]$ /opt/adnnagios/libexec/check_procs-new -V
check_procs v2019 (nagios-plugins 1.4.12)


[EMAIL PROTECTED] ~]$ time /opt/adnnagios/libexec/check_procs-new -t 60
PROCS OK: 1445 processes

real0m32.551s
user0m1.641s
sys 0m26.088s

[EMAIL PROTECTED] ~]$ time /opt/adnnagios/libexec/check_procs-1.45 -t 60
PROCS OK: 1477 processes

real0m0.344s
user0m0.056s
sys 0m0.309s

Still runs about 100x slower than version 1.45.

[EMAIL PROTECTED] ~]$ uname -a
SunOS adnsoz05 5.10 Generic_127127-11 sun4u sparc SUNW,SPARC-Enterprise

[EMAIL PROTECTED] ~]$ prtdiag
System Configuration:  Sun Microsystems  sun4u Sun SPARC Enterprise 
M4000 Server
System clock frequency: 1012 MHz
Memory size: 32768 Megabytes

 CPUs 


   CPU CPU RunL2$CPU 
   CPU
LSB   Chip ID MHz MB 
Impl. Mask
---          --- 
- 
  00 0  0,   1,   2,   3   2150   5.0 
  6  147
  00 1  8,   9,  10,  11   2150   5.0 
  6  147

 Memory Configuration 


Memory  Available   Memory DIMM# of  Mirror 
Interleave
LSBGroup   SizeStatus SizeDIMMs ModeFactor
-----  --  -----  - --- 
--
  00A16384MBokay   2048MB  8 no   4-way
  00B16384MBokay   2048MB  8 no   4-way



Bye
Bernd



 
   Duncs
 
 On 4 Sep 2008, at 14:02, Bernd Nies wrote:
 
 Hi,

 Something bad happened to the check_proc plugin between version 1.45 and
 v1991. For counting ca 1700 processes on a Sun Enterprise M4000 it takes
 45 seconds and sometimes longer. An older version was much faster qirh
 0.3 seconds.

 I compiled Nagios plugins 1.4.12 on a Solaris 9 with GCC 3.4.6 to get
 binaries that can run on Solaris 8, 9 and 10.



 [EMAIL PROTECTED] ~]$ /opt/adnnagios/libexec/check_procs-1.45 -V
 check_procs (nagios-plugins 1.4.1) 1.45

 [EMAIL PROTECTED] ~]$ /opt/adnnagios/libexec/check_procs -V
 check_procs v1991 (nagios-plugins 1.4.12)



 [EMAIL PROTECTED] ~]$ time /opt/adnnagios/libexec/check_procs-1.45
 PROCS OK: 1695 processes

 real0m0.320s
 user0m0.051s
 sys 0m0.296s

 [EMAIL PROTECTED] ~]$ time /opt/adnnagios/libexec/check_procs -t 60
 PROCS OK: 1664 processes

 real0m45.543s
 user0m2.851s
 sys 0m41.231s


 Any ideas what's going wrong?

 Bye
 Bernd


 -
 This SF.Net email is sponsored by the Moblin Your Move Developer's 
 challenge
 Build the coolest Linux based applications with Moblin SDK  win great 
 prizes
 Grand prize is a trip for two to an Open Source event anywhere in the 
 world
 http://moblin-contest.org/redirect.php?banner_id=100url=/
 ___
 Nagios-users mailing list
 Nagios-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/nagios-users
 ::: Please include Nagios version, plugin version (-v) and OS when 
 reporting any issue.
 ::: Messages without supporting info will risk being sent to /dev/null
 


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


[Nagios-users] Acknowledge problems via e-mail

2008-09-15 Thread Jorge Peña

Hello list,
 
I have a running instalation of Nagios capable to acknowledge via web interface 
and SMS (I followed some tutorial for that).
 
I guessed Nagios had implemented by default the acknowledgementent via e-mail 
by default just replying to the e-mail but I discovered that it doesn't work.
 
Somebody did? how?
 
Regards,
Jorge
 
 
_
¿Sigue el calor? Consulta MSN El tiempo
http://eltiempo.es.msn.com/-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null

Re: [Nagios-users] Acknowledge problems via e-mail

2008-09-15 Thread Terry Davis
On Mon, Sep 15, 2008 at 10:32 AM, Jorge Peña [EMAIL PROTECTED] wrote:

  Hello list,

 I have a running instalation of Nagios capable to acknowledge via web
 interface and SMS (I followed some tutorial for that).

 I guessed Nagios had implemented by default the acknowledgementent via
 e-mail by default just replying to the e-mail but I discovered that it
 doesn't work.

 Somebody did? how?

 Regards,
 Jorge


1) install postfix
2) install procmail
3) use the following procmailrc for the nagios user:
LOGFILE=$HOME/.procmailrc.log
VERBOSE=yes
PATH=/usr/bin
:0
* ^Subject:[]*\/[^  ].*
| /usr/lib/nagios/eventhandlers/processmail ${MATCH}

4) /usr/lib/nagios/eventhandlers/processmail is at the end of this email
5) the program assumes notifications are formatted like mine.  I put them at
the end of this email too.
6) when you receive an alert on your blackberry while at the bar, simply
reply to the email and prepend the subject of the alert with:
something ack

I'm probably missing some things so if it doesn't work right away, post back
and I'll help as much as I can.  This comes with no warranty.  Its poorly
written perl.  It probably has a huge security hole.  There's probably a
better way to do this.  It very well may turn your servers into an Atom bomb
and blow up the moon.  Just warning you...  :)

Thanks,
Terry




define command{
command_namenotify-by-email
command_line/usr/bin/printf %b Notification Type:
$NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress:
$HOSTADDRESS$\nState: $SERVICESTATE$\nNotification Number:
$SERVICENOTIFICATIONNUMBER$\n\nDate/Time: $LONGDATETIME$\n\nAdditional
Info:\n\n$SERVICEOUTPUT$ | /usr/lib/nagios/eventhandlers/notification
$SERVICENOTIFICATIONNUMBER$ localhost [EMAIL PROTECTED] $CONTACTEMAIL$ **
$NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **
service
}

define command{
command_namenotify-by-epager
command_line/usr/bin/printf %b Service: $SERVICEDESC$\nHost:
$HOSTNAME$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\nNotification
Number: $SERVICENOTIFICATIONNUMBER$\nInfo: $SERVICEOUTPUT$\nDate:
$LONGDATETIME$ | /usr/bin/sendEmail -s localhost -f [EMAIL PROTECTED] -t
$CONTACTEMAIL$ -u $NOTIFICATIONTYPE$: $HOSTALIAS$/$SERVICEDESC$ is
$SERVICESTATE$
}

define command{
command_namehost-notify-by-email
command_line/usr/bin/printf %b Notification Type:
$NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nNotification
Number: $HOSTNOTIFICATIONNUMBER$\nAddress: $HOSTADDRESS$\nInfo:
$HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n |
/usr/lib/nagios/eventhandlers/notification $HOSTNOTIFICATIONNUMBER$
localhost [EMAIL PROTECTED] $CONTACTEMAIL$ Host $HOSTSTATE$ alert for
$HOSTNAME$! host
}

define command{
command_namehost-notify-by-epager
command_line/usr/bin/printf %b Host '$HOSTALIAS$' is
$HOSTSTATE$\nInfo: $HOSTOUTPUT$\nTime: $LONGDATETIME$ | /usr/bin/sendEmail
-s localhost -f [EMAIL PROTECTED] -t $CONTACTEMAIL$ -u $NOTIFICATIONTYPE$
alert - Host $HOSTNAME$ is $HOSTSTATE$
}



#!/usr/bin/perl

$correctpassword = 'something';
$subject = $ARGV[0];
$now = `/bin/date +%s`;
chomp $now;
$commandfile = '/var/log/nagios/rw/nagios.cmd';

if ($subject =~ /Host/ ){
($password, $what, $junk, $junk, $junk, $junk, $junk, $host) =
split(/ /, $subject);
($host) = ($host) =~ /(.*)\!/;
} else {
($foo, $bar) = split(/\//, $subject);
($password, $what, $junk, $junk, $junk, $junk, $junk, $host) =
split(/ /, $foo);
($service) = $bar =~ /^(.*) is.*$/;
}

$password =~ s/^\s+//;
$password =~ s/\s+$//;

print $password\t$what\t$host\t$service\n;

unless ($password =~ /$correctpassword/i) {
print exiting...wrong password\n;
exit 1;
}

# ack
if ($subject =~ /Host/ ) {
$ack =
ACKNOWLEDGE_HOST_PROBLEM;$host;1;1;1;email;email;acknowledged through
email;
} else {
$ack =
ACKNOWLEDGE_SVC_PROBLEM;$host;$service;1;1;1;email;acknowledged through
email;
}

if ($what =~ /ack/i) {
sub_print($ack);
} else {
print no valid commands...exiting\n;
exit 1;
}


sub sub_print {
$narf=shift;
open(F, $commandfile) or die cant;
print F [$now] $narf\n;
close F;
}
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any 

[Nagios-users] intermittent CGI failure

2008-09-15 Thread nagios
Installed 3.0.3 from source on OpenBSD 4.3 (sparc64).  Everything works,
but every so often the CGI's will fail.

e.g. If I refresh, say, status.cgi?host=all 10 times in a row, it'll fail
at least once or twice.

I can reproduce using both Apache and nginx.

Here's Apache error log snippet: Premature end of script headers:
/var/www/nagios/cgi-bin/status.cgi

Here's nginx error log snippet: upstream closed prematurely FastCGI
stdout while reading response header from upstream

Familiar issue to anyone?  Next steps to debug?

I cannot reproduce by running, manually from command shell:
export REQUEST_METHOD=GET
./status.cgi




-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


[Nagios-users] permissions on nagios.cmd

2008-09-15 Thread Julie
Everyone here has been great about helping me on my previous problem - and
now I have a new one.

I have read the FAQ and recreated the file and check permissions several
times, but no matter what I do I can't get past:

*Error: Could not stat() command file '/usr/local/nagios/var/rw/nagios.cmd'!
*
*The external command file may be missing, Nagios may not be running, and/or
Nagios may not be checking external commands. *
*An error occurred while attempting to commit your command for processing.*

I should explain - I rebuilt nagios on a new system and then rsync'ed key
config files. I was moving from 32 bit to 64 bit and wanted to recompile
everything with 64 bit libraries.

At first I thought the rsync caused some problems. So following the FAQ - I
deleted /usr/local/nagios/var/rw and recreated.

drwxrwsr-x 2 nagios nagios   4096 Sep 14 08:44 rw
prw-rw 1 nagios nagios 0 Sep 14 08:44 nagios.cmd


and both the user and group that runs nagios is nagios. I added apache to
the nagios group. Bust still the error occurs. I have restarted and
rebooted. I do have selinux running, but even tried permissive to see if
that was the problem. I also ran

chcon -R -t httpd_sys_content_t /usr/local/nagios/sbin/
chcon -R -t httpd_sys_content_t /usr/local/nagios/share/
chcon -R -t httpd_sys_content_t /usr/local/nagios/var

and still no luck.

Help?!
~J~
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null

[Nagios-users] NRPE 2.12 compile failure

2008-09-15 Thread Andy Shellam
Hi,

I've just had a new Nagios server delivered; it's running Debian 4. I've 
installed the latest Apache, PHP, OpenSSL packages and Nagios 3.0.3 and 
NRPE 2.12.
However it looks like NRPE isn't setting the include flags correctly for 
the compiler.

OpenSSL is installed in /usr/local/openssl, and Nagios in /usr/local/nagios.

My configure line is:

./configure --prefix=/usr/local/nagios --with-ssl=/usr/local/openssl 
--with-ssl-inc=/usr/local/openssl/include 
--with-ssl-lib=/usr/local/openssl/lib --with-nrpe-user=nagios 
--with-nrpe-group=localservice

Configure completes successfully and generates the OpenSSL parameters 
successfully:

*** Generating DH Parameters for SSL/TLS ***
Generating DH parameters, 512 bit long safe prime, generator 2
This is going to take a long time
 etc 

make all then fails with a LOT of the following errors:

/usr/local/openssl/include/openssl/pem.h:69:25: error: openssl/evp.h: No 
such file or directory
/usr/local/openssl/include/openssl/pem.h:70:26: error: openssl/x509.h: 
No such file or directory
/usr/local/openssl/include/openssl/pem.h:71:26: error: openssl/pem2.h: 
No such file or directory
In file included from ../include/config.h:241,
from ../include/common.h:24,
from nrpe.c:21:
/usr/local/openssl/include/openssl/pem.h:142: error: expected 
specifier-qualifier-list before ‘EVP_ENCODE_CTX’

Evidently the include path is not been set to 
/usr/local/openssl/include as requested in the configure script. If I 
try and set with-ssl-inc and with-ssl-lib to anything else (or omit 
them), it fails saying the SSL libraries were not found.

If I look inside the Makefile, it looks like the configure script has 
added an additional openssl to the include path. OpenSSL tries to find 
openssl/*.h so it's actually trying to find 
/usr/local/openssl/include/openssl/openssl/*.h whcih is incorrect.

--
root /var/software/nrpe-2.12 # cat Makefile|grep include
SRC_INCLUDE=./include/
CFLAGS=-g -O2 -I/usr/local/openssl/include/openssl -DHAVE_CONFIG_H
--

Has anyone else had similar problems?

Andy

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


Re: [Nagios-users] permissions on nagios.cmd

2008-09-15 Thread Terry Davis
On Mon, Sep 15, 2008 at 12:24 PM, Julie [EMAIL PROTECTED] wrote:

 Everyone here has been great about helping me on my previous problem - and
 now I have a new one.

 I have read the FAQ and recreated the file and check permissions several
 times, but no matter what I do I can't get past:

 *Error: Could not stat() command file
 '/usr/local/nagios/var/rw/nagios.cmd'!*
 *The external command file may be missing, Nagios may not be running,
 and/or Nagios may not be checking external commands. *
 *An error occurred while attempting to commit your command for processing.
 *

 I should explain - I rebuilt nagios on a new system and then rsync'ed key
 config files. I was moving from 32 bit to 64 bit and wanted to recompile
 everything with 64 bit libraries.

 At first I thought the rsync caused some problems. So following the FAQ - I
 deleted /usr/local/nagios/var/rw and recreated.

 drwxrwsr-x 2 nagios nagios   4096 Sep 14 08:44 rw
 prw-rw 1 nagios nagios 0 Sep 14 08:44 nagios.cmd


 and both the user and group that runs nagios is nagios. I added apache to
 the nagios group. Bust still the error occurs. I have restarted and
 rebooted. I do have selinux running, but even tried permissive to see if
 that was the problem. I also ran

 chcon -R -t httpd_sys_content_t /usr/local/nagios/sbin/
 chcon -R -t httpd_sys_content_t /usr/local/nagios/share/
 chcon -R -t httpd_sys_content_t /usr/local/nagios/var

 and still no luck.

 Help?!
 ~J~


What are the following values set to in nagios.cfg:

check_external_commands
command_check_interval
command_file

Thanks,
Terry
*
*
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null

[Nagios-users] [Fwd: NRPE 2.12 compile failure]

2008-09-15 Thread Andy Shellam
FYI if I force the compiler flags, it works.  I've also tried on another 
Debian 4 box and it also fails the same.

The configure line below forces the compiler flags to be correct:

CFLAGS=-I/usr/local/openssl/include ./configure 
--prefix=/usr/local/nagios --with-ssl=/usr/local/openssl 
--with-ssl-inc=/usr/local/openssl/include 
--with-ssl-lib=/usr/local/openssl/lib --with-nrpe-user=nagios 
--with-nrpe-group=localservice

Thanks,
Andy

 Original Message 
Subject:[Nagios-users] NRPE 2.12 compile failure
Date:   Mon, 15 Sep 2008 17:57:44 +0100
From:   Andy Shellam [EMAIL PROTECTED]
To: nagios-user Mailinglist nagios-users@lists.sourceforge.net



Hi,

I've just had a new Nagios server delivered; it's running Debian 4. I've 
installed the latest Apache, PHP, OpenSSL packages and Nagios 3.0.3 and 
NRPE 2.12.
However it looks like NRPE isn't setting the include flags correctly for 
the compiler.

OpenSSL is installed in /usr/local/openssl, and Nagios in /usr/local/nagios.

My configure line is:

./configure --prefix=/usr/local/nagios --with-ssl=/usr/local/openssl 
--with-ssl-inc=/usr/local/openssl/include 
--with-ssl-lib=/usr/local/openssl/lib --with-nrpe-user=nagios 
--with-nrpe-group=localservice

Configure completes successfully and generates the OpenSSL parameters 
successfully:

*** Generating DH Parameters for SSL/TLS ***
Generating DH parameters, 512 bit long safe prime, generator 2
This is going to take a long time
 etc 

make all then fails with a LOT of the following errors:

/usr/local/openssl/include/openssl/pem.h:69:25: error: openssl/evp.h: No 
such file or directory
/usr/local/openssl/include/openssl/pem.h:70:26: error: openssl/x509.h: 
No such file or directory
/usr/local/openssl/include/openssl/pem.h:71:26: error: openssl/pem2.h: 
No such file or directory
In file included from ../include/config.h:241,
from ../include/common.h:24,
from nrpe.c:21:
/usr/local/openssl/include/openssl/pem.h:142: error: expected 
specifier-qualifier-list before ‘EVP_ENCODE_CTX’

Evidently the include path is not been set to 
/usr/local/openssl/include as requested in the configure script. If I 
try and set with-ssl-inc and with-ssl-lib to anything else (or omit 
them), it fails saying the SSL libraries were not found.

If I look inside the Makefile, it looks like the configure script has 
added an additional openssl to the include path. OpenSSL tries to find 
openssl/*.h so it's actually trying to find 
/usr/local/openssl/include/openssl/openssl/*.h whcih is incorrect.

--
root /var/software/nrpe-2.12 # cat Makefile|grep include
SRC_INCLUDE=./include/
CFLAGS=-g -O2 -I/usr/local/openssl/include/openssl -DHAVE_CONFIG_H
--

Has anyone else had similar problems?

Andy

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


Re: [Nagios-users] permissions on nagios.cmd

2008-09-15 Thread Julie
Never mind - it was one last setting on SElinux..

SELinux is preventing cmd.cgi (httpd_sys_script_t) getattr to
/usr/local/nagios/var/rw/nagios.cmd

I added a change to SELinux policy and it is working now... I needed to add
it for the file, not just the folder..

chcon -R -t httpd_sys_content_t /usr/local/nagios/var/rw/nagios.cmd

thanks..


On Mon, Sep 15, 2008 at 12:51 PM, Julie [EMAIL PROTECTED] wrote:

 all what I would expect:

 nagios_group=nagios
 command_check_interval=-1
 command_file=/usr/local/nagios/var/rw/nagios.cmd

 On Mon, Sep 15, 2008 at 12:46 PM, Terry Davis [EMAIL PROTECTED]wrote:

 On Mon, Sep 15, 2008 at 12:24 PM, Julie [EMAIL PROTECTED] wrote:

 Everyone here has been great about helping me on my previous problem -
 and now I have a new one.

 I have read the FAQ and recreated the file and check permissions several
 times, but no matter what I do I can't get past:

 *Error: Could not stat() command file
 '/usr/local/nagios/var/rw/nagios.cmd'!*
 *The external command file may be missing, Nagios may not be running,
 and/or Nagios may not be checking external commands. *
 *An error occurred while attempting to commit your command for
 processing.*

 I should explain - I rebuilt nagios on a new system and then rsync'ed key
 config files. I was moving from 32 bit to 64 bit and wanted to recompile
 everything with 64 bit libraries.

 At first I thought the rsync caused some problems. So following the FAQ -
 I deleted /usr/local/nagios/var/rw and recreated.

 drwxrwsr-x 2 nagios nagios   4096 Sep 14 08:44 rw
 prw-rw 1 nagios nagios 0 Sep 14 08:44 nagios.cmd


 and both the user and group that runs nagios is nagios. I added apache to
 the nagios group. Bust still the error occurs. I have restarted and
 rebooted. I do have selinux running, but even tried permissive to see if
 that was the problem. I also ran

 chcon -R -t httpd_sys_content_t /usr/local/nagios/sbin/
 chcon -R -t httpd_sys_content_t /usr/local/nagios/share/
 chcon -R -t httpd_sys_content_t /usr/local/nagios/var

 and still no luck.

 Help?!
 ~J~


 What are the following values set to in nagios.cfg:

 check_external_commands
 command_check_interval
 command_file

 Thanks,
 Terry
 *
 *



-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null

Re: [Nagios-users] permissions on nagios.cmd

2008-09-15 Thread Terry Davis
On Mon, Sep 15, 2008 at 1:01 PM, Julie [EMAIL PROTECTED] wrote:

 Never mind - it was one last setting on SElinux..

 SELinux is preventing cmd.cgi (httpd_sys_script_t) getattr to
 /usr/local/nagios/var/rw/nagios.cmd

 I added a change to SELinux policy and it is working now... I needed to add
 it for the file, not just the folder..

 chcon -R -t httpd_sys_content_t /usr/local/nagios/var/rw/nagios.cmd

 thanks..


Why's that matter if SELINUX was configured as permissive?
-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null

[Nagios-users] Service alerts after host down?

2008-09-15 Thread Jay Chandler
Howdy.

I fear I have something misconfigured.  A host in our environment will 
go down, and I'll get a notification that the host is down.  However, 
I'll still keep getting Service alerts after the host notification, 
which I don't get; logically, if a host is hard down, NONE of its 
services should return as up.

Assuming I'm not mistaken in this belief, what portion of my config 
files shall I submit for review?

Regards,

-- 
Jay Chandler / KB1JWQ
Living Legend / Systems Exorcist
Today's Excuse: Communist revolutionaries taking over the server room and 
demanding all the computers in the building or they shoot the sysadmin. Poor 
misguided fools.


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


Re: [Nagios-users] Service alerts after host down?

2008-09-15 Thread Marc Powell

On Sep 15, 2008, at 6:30 PM, Jay Chandler wrote:

 Howdy.

 I fear I have something misconfigured.  A host in our environment will
 go down, and I'll get a notification that the host is down.  However,
 I'll still keep getting Service alerts after the host notification,
 which I don't get; logically, if a host is hard down, NONE of its
 services should return as up.

Yup. nagios knows this. Service alert suppression is automagic. The  
first section of the following page explains --

http://nagios.sourceforge.net/docs/2_0/networkreachability.html

 Assuming I'm not mistaken in this belief, what portion of my config
 files shall I submit for review?

You just need to make sure that your host's check_command returns DOWN  
when it's down. If that is currently the case, and you see that  
reflected in the web interface, be sure that you don't have multiple  
nagios daemons running at the same time.

--
Marc


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


Re: [Nagios-users] Service alerts after host down?

2008-09-15 Thread Jay Chandler
Marc Powell wrote:
 On Sep 15, 2008, at 6:30 PM, Jay Chandler wrote:

   
 Howdy.

 I fear I have something misconfigured.  A host in our environment will
 go down, and I'll get a notification that the host is down.  However,
 I'll still keep getting Service alerts after the host notification,
 which I don't get; logically, if a host is hard down, NONE of its
 services should return as up.
 

 Yup. nagios knows this. Service alert suppression is automagic. The  
 first section of the following page explains --

 http://nagios.sourceforge.net/docs/2_0/networkreachability.html

   
 Assuming I'm not mistaken in this belief, what portion of my config
 files shall I submit for review?
 

 You just need to make sure that your host's check_command returns DOWN  
 when it's down. If that is currently the case, and you see that  
 reflected in the web interface, be sure that you don't have multiple  
 nagios daemons running at the same time.

   
Thanks for your reply-- I've made a few changes here and am awaiting the 
next maintenance window (or outtage!) to verify that this works now.  I 
may change the check_host_alive to use an SSH query instead of an ICMP 
echo request; there are several situations in which the box is for all 
intents and purposes down, but the IP stack still responds to ping.

-- 
Jay Chandler / KB1JWQ
Living Legend / Systems Exorcist
Today's Excuse: Communist revolutionaries taking over the server room and 
demanding all the computers in the building or they shoot the sysadmin. Poor 
misguided fools.


-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null


Re: [Nagios-users] sudo /etc/init.d/nagios

2008-09-15 Thread James
Matthew Stier wrote:
 First, I suspect you have two typo's on the subject line.

 Second, If sudo won't run sudo, you probably have sudo configured not 
 to be run as root.

 Third, boot scripts should be written to be run by root, and if it 
 needs to change users, that should be done with 'su' with the '-c' 
 option, and a simple command-line.
I can only run the script as sudo and I can't reboot the machine.
Is there any other way to change users besides su since I can't run su?

 Fourth, boot scripts should test for everything.  If you reference 
 something outside the core operating system, you should test that it 
 is present, rather than blindly assuming it is there, and crashing.


 James wrote:
 I'm having trouble running the init script with sudo.
 I changed the su to use sudo but then I can't run the script with sudo
 because sudo can't run sudo.

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK  win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100url=/
___
Nagios-users mailing list
Nagios-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting 
any issue. 
::: Messages without supporting info will risk being sent to /dev/null