Undefined subroutine &Embed::Persistent::eval_file called. in check_disk_smb

Stanley.Hopcroft at Dest.gov.au Stanley.Hopcroft at Dest.gov.au
Wed May 24 01:22:40 CEST 2006


Dear Sir,

I am writing to thank you for your letter and say,

>-----Original Message-----

>Message: 15
>Date: Tue, 23 May 2006 14:10:03 +0200 (CEST)
>From: =?iso-8859-1?q?jacobo=20garc=EDa?= <ies_med at yahoo.es>
>To: nagios-users at lists.sourceforge.net
>Subject: [Nagios-users] Undefined subroutine 
>&Embed::Persistent::eval_file called.  in check_disk_smb
>
>Under Nagios i had this problem when running
>check_disk_smb
>
>"Undefined subroutine &Embed::Persistent::eval_file
>called. "
>

It sounds like that you have a Nagios built with embedded Perl.

(you can check by strings </Path/to/>nagios | grep -i perl | head -5. If
you see
libperl.so
Perl_croak
Perl_markstack_grow
Perl_croak_nocontext
Perl_save_int

then you have a Perl interpreter built into Nagios).

If this is not the case, I can't help.

Unfortunately if your Nagios does have Perl in it, the Perl driver
(p1.pl) seems not to be where Nagios expects it.

Look at your nagios.cfg

(eg
[sh1517 at acisf011 Dhcp]$ grep -i P1 /etc/nagios/nagios.cfg 
# P1.PL FILE LOCATION
# This value determines where the p1.pl perl script (used by the
p1_file=/usr/bin/p1.pl
[sh1517 at acisf011 Dhcp]$ 
)

and check if p1.pl is in the location nagios.cfg says it should be.

If it is, I don't know what is happening.

If not, try and locate it - you can get it from the Nagios CVS or from
the corresponding dist tarball or the RPM/package - and put it there.
You could also check its not hiding somewhere else in the file system. 

If you can get a copy of p1.pl then either relocate it or put it in the
path specified by nagios.cfg (p1.pl is used only by Nagios so moving it
won't break anything). You may have to restart Nagios for the change to
take effect.

The file is plain text, pure Perl. p1.pl defines the subroutine that
Nagios is trying to have Perl call.

Finally, if you don't have a good reason to use embedded Perl, you
probably shouldn't be using it. If you don't want to use embedded Perl,
you can't turn it off at run time. The only option is replacing the
Nagios binary with one compiled without embedded Perl. The Dag Wieers
Redhat RPMs for Nagios all build with embedded Perl so if you use RPMs,
you would need to choose another RPM or hack the Dag SPEC file to not
build embedded Perl.


>
>when i run from command line i response on 2 lines,
>but it seems to be ok.
>
>i dont know what to do.
>
>

Yours sincerely.


-------------------------------------------------------
All the advantages of Linux Managed Hosting--Without the Cost and Risk!
Fully trained technicians. The highest number of Red Hat certifications in
the hosting industry. Fanatical Support. Click to learn more
http://sel.as-us.falkag.net/sel?cmd=lnk&kid7521&bid$8729&dat1642
_______________________________________________
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