Possibly it's a security issue.  I assume SA is running as a service.  Does the service account have rights to connect to the remote event log?

Mark Bradshaw
Director of Online Services
DREAM3
http://www.dream3.org
(866) 7DREAM3

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 14, 2004 9:44 AM
To: [EMAIL PROTECTED]
Subject: RE: [SA-list] Event log check


Log looks OK:

        14 October 2004 15:20:49 External check of :c:\perl\bin\perl.exe c:\perl\bin\checkevt.pl -p noos-dc01:security:10:1:*:*:id:644
        14 October 2004 15:20:50  0
        14 October 2004 15:20:50 DoExternalCheck : returned value :  0

The trouble is, this is wrong! There *is* an entry with ID 644, which shows up (after 1 minute or so) if you run it on the command line.

Interestingly, if I modify the command to be, say:

        c:\perl\bin\perl.exe nonexistantfile -p noos-dc01:security:10:1:*:*:id:644

it returns errorlevel 2, rather than a "can't open script" error. Not sure quite what that suggests...

Ian

Ian K Gray
OEL IS - European Network Operations
Tel: +44 1236 502661
Mob: +44 7881 518854



"Mark Bradshaw" <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]

14/10/2004 15:13

Please respond to
[EMAIL PROTECTED]

To
<[EMAIL PROTECTED]>
cc
Subject
RE: [SA-list] Event log check





Check the log.

Mark Bradshaw
Director of Online Services
DREAM3

http://www.dream3.org
(866) 7DREAM3




From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent:
Thursday, October 14, 2004 8:54 AM
To:
[EMAIL PROTECTED]
Subject:
RE: [SA-list] Event log check



Andy,


Thanks for that, although it's still not working. Your suggested line:


       c:\perl\bin\perl.exe c:\perl\bin\checkevt.pl -p noos-dc01:security:10:1:*:*:id:644


works on the command line (runs for about a minute and then returns full details of the event), but if I put it in SA it just returns errorlevel 0 within about 2 seconds. Clearly it's not processing the full command.


Any more ideas?


Ian



Ian K Gray
OEL IS - European Network Operations
Tel: +44 1236 502661
Mob: +44 7881 518854


"Carroll, Andy" <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]

14/10/2004 12:44

Please respond to
[EMAIL PROTECTED]


To
[EMAIL PROTECTED]
cc
Subject
RE: [SA-list] Event log check







Ian,

 

here is an example from my Servers Alive installation:

 

c:\perl\bin\perl.exe "c:\data\servers alive\sa_dev\checkevt.pl" -p benotesmail01:system:15:1:*:*:id:6009

 

I have numerous eventlog checks that are running and they all use this version of the check (checkevt.pl) and I have never had problems with them.

 

The first part - c:\perl\bin\perl.exe - specifies the full path to the perl interpreter,

 

The second part - "c:\data\servers alive\sa_dev\checkevt.pl" - specifies the full path to the checkevt.pl script

 

The third part -  -p benotesmail01:system:15:1:*:*:id:6009 - is the commandline parameters for your check, this third part does not need to be in quotes, however if the path of either of the first 2 parts contains spaces, i.e. your perl installation or the checkevt.pl script resides under the c:\program files\ area, then you need to wrap these parts in quotes.

 

e.g.

 

when I installed my perl in the program files directory

 

"c:\program files\perl\bin\perl.exe" "c:\data\servers alive\sa_dev\checkevt.pl" -p benotesmail01:system:15:1:*:*:id:6009

 
 

looking at your commanline, I would of expected the following to work, notice no quotes used, as there are no spaces in your paths.

 

c:\perl\bin\perl.exe c:\perl\bin\checkevt.pl -p noos-dc01:security:10:1:*:*:id:644

 

Hope this helps,

 

Regards,

 

Andy

 

-----Original Message-----
From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]On Behalf Of [EMAIL PROTECTED]
Sent:
14 October 2004 10:15
To:
[EMAIL PROTECTED]
Cc:
[EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject:
RE: [SA-list] Event log check



Tried that. Tried it without the quotes. Tried it with single quotes. Tried moving the .pl script to the same directory as the perl interpreter:


"c:\perl\bin\perl.exe c:\perl\bin\checkevt.pl -p noos-dc01:security:10:1:*:*:id:644"


None of this seems to work. Help! Has anyone else got this working?


Ian



Ian K Gray
OEL IS - European Network Operations
Tel: +44 1236 502661
Mob: +44 7881 518854

"Dirk Bulinckx" <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]

14/10/2004 09:58

Please respond to
[EMAIL PROTECTED]


To
<[EMAIL PROTECTED]>
cc
Subject
RE: [SA-list] Event log check









The complete commandline should be within the quotes and not just the path/name of the script., and also I think that you should include the perl interpretor within the command.  The association between a .PL file and the perl interpretor isn't done when executing a command via Servers Alive (the API calls we're using are apparently not doing this).

 

Dirk.




From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED]
Sent:
Thursday, October 14, 2004 9:56 AM
To:
[EMAIL PROTECTED]
Subject:
[SA-list] Event log check



OK, now I'm trying the old perl checker. It seems to work on the command line, but if I put it into SA (using external errorlevel check) it comes up with an unknown application error:


14 October 2004 08:48:30 External check of :"C:\Program Files\salive\external\checkevt.pl" -p noos-dc01:security:10:1:*:*:id:644

14 October 2004 08:48:30 ERR : Unknown application ("C:\Program Files\salive\external\checkevt.pl" -p noos-dc01:security:10:1:*:*:id:644)


What am I doing wrong??


Thanks,


Ian


Ian K Gray
OEL IS - European Network Operations
Tel: +44 1236 502661
Mob: +44 7881 518854

Reply via email to