[mrtg] Re: Problems with MRTG threshold checking when running as a service
Erwan PERROTIN
eperrotin at contentia.fr
Fri Oct 20 15:20:16 MEST 2006
Hi,
I have the same problem. I'm using MRTG 2.14.17 on Windows 2000. When I use
perl, no problem, the threshold script started but I would like use wperl.
Anybody have a solution ?
Thanks !
Erwan
I have solved this issue and thought I would post the solution in case
anyone else suffers it and does a search of the archives. I managed to
track it down to my using "wperl" rather than "perl" to run MRTG. Not
being that familiar with perl I had not really appreciated the
difference between the two. When I switched to using "perl" to run MRTG
the threshold script started executing fine.
Thanks to those who suggested what my problem might be.
Simon.
-----Original Message-----
From: mrtg-bounce at list.ee.ethz.ch [ <mailto:mrtg-bounce at list.ee.ethz.ch>
mailto:mrtg-bounce at list.ee.ethz.ch]
On Behalf Of Fairey, Simon
Sent: 03 August 2004 13:14
To: mrtg at list.ee.ethz.ch
Subject: [mrtg] Problems with MRTG threshold checking when running as a
service
Hi,
I'm using MRTG 2.10.14 on Windows 2003 without problem apart from when
trying to use the threshold checking features when MRTG is running as
a service. If I start MRTG from the command line (using the same
syntax used when running as the service) the threshold stuff works
fine - the batch file specified in ThreshProgI does what its supposed
to do.
When MRTG is run as a service nothing appears to happen. I had thought
it was permissions related but have ruled that out by running MRTG
from the command line as the same user the service is running as.
I have seen another post to this group with the same issue and there
was some suggestion that it might be related to path names not being
absolute. I have also ruled this out - the service (using srvany)
starts MRTG as:
C:\perl\bin\wperl.exe c:\mrtg-2.10.14\bin\mrtg --logging=eventlog
c:\<folder>\<mrtg config file>
and the threshold program:
ThreshProgI[<name>]: c:\folder\test.bat
To keep things simple whilst trying to identify the cause of this
problem the batch file just echos some text to a file (again using
absolute path name to the file).
I've tried running filemon (from Sysinternals) to see get some idea of
what might be going wrong. When MRTG is running from the command line
you can see the wperl process open the batch file, query is then close
it, and then a cmd.exe process spawns, which I presume is executing
the batch file. When MRTG is running as a service the wperl process
queries the batch file as before, but no cmd.exe process spawns. The
relevant user has execute permissions on cmd.exe.
There also does not appear to be any log messages indicating a
problem.
Can anyone suggest something I am missing / could check?
Thanks,
--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive http://lists.ee.ethz.ch/mrtg
FAQ http://faq.mrtg.org Homepage http://www.mrtg.org
WebAdmin http://lists.ee.ethz.ch/lsg2.cgi
More information about the mrtg
mailing list