Nagios fails to start afteradding'check_logs.pl' service

Marc Powell marc at ena.com
Fri Aug 15 16:57:44 CEST 2008



> -----Original Message-----
> From: nagios-users-bounces at lists.sourceforge.net [mailto:nagios-users-
> bounces at lists.sourceforge.net] On Behalf Of Bret Goodfellow
> Sent: Friday, August 15, 2008 8:27 AM
> To: Jon Angliss; nagios-users at lists.sourceforge.net
> Subject: Re: [Nagios-users] Nagios fails to start
> afteradding'check_logs.pl' service


> My last post has output from "strace".  I'm not sure how to read it,
but
> it appears to me that there may be a rights issue.  What does "-1
ENOTTY
> (Inappropriate ioctl for device)" mean?  Here again, are the last few
> lines from the strace:

Nothing to worry about in this case. Since you're not running the
command from a shell, NOTTY is expected.

> 11:59:14 open("/usr/lib64/nagios/plugins/check_logs.pl", O_RDONLY) = 8
> 11:59:14 ioctl(8, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7fbfffa590) = -1
> ENOTTY (Inappropriate ioctl for device)
> 11:59:14 lseek(8, 0, SEEK_CUR)          = 0
> 11:59:14 fstat(8, {st_mode=S_IFREG|0755, st_size=6609, ...}) = 0
> 11:59:14 fcntl(8, F_SETFD, FD_CLOEXEC)  = 0
> 11:59:14 fstat(8, {st_mode=S_IFREG|0755, st_size=6609, ...}) = 0
> 11:59:14 read(8, "#!/usr/bin/perl -w\n#\n# Log file "..., 6609) = 6609
> 11:59:14 close(8)                       = 0
> 11:59:14 --- SIGSEGV (Segmentation fault) @ 0 (0) ---

This is an interesting bit. The plugin is a perl program. Nagios loaded
it and would have been ready to execute it. Perl plugins could possibly
be treated 'specially' and have special requirements if you compile
Nagios with the embedded perl interpreter (ePN) enabled. Did you do so?
In the command{} definition for check_logs.pl, try disabling the use of
ePN by prefacing the command with your /path/to/perl --

(from memory)
define command {
command_name   check_logs ; or whatever it is
command_line   /path/to/perl $USER1$/check_logs.pl (... other stuff
here)
}

--
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=100&url=/
_______________________________________________
Nagios-users mailing list
Nagios-users at 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





More information about the Users mailing list