Hi,
I'm trying to figure out if a specific user is being used when an alert executes a VBscript from Orion, but I can't seem to find the answer (checked eventvwr). I wrote a script using WMI and inherited the correct permissions. When I got this portion working, I added a function to email me when the script gets executed, however it is no longer working from Orion. The script works fine when I run it manually from command line so I think it has to do with permissions (I had the same problem with the WMI portion).
strComputer has ${NodeName} passed in
strApplication has ${ApplicationName} passed in
The portion below is what I'm using to send an email. It's very basic and works fine when I run manually.
In the trigger, I have d:\scripts\reboot.vbs ${NodeName} ${ApplicationName}
strComputer = wscript.Arguments(0) strApplication = wscript.arguments(1)
Set objMessage = CreateObject("CDO.Message") With objMessage .Subject = strComputer & " : " & strApplication .From = "XXXXXXX@xxxxx.com" .To = "XXXXXXX@xxxxx.com" .TextBody = strApplication & " was in critical state" & vblf & strComputer & " rebooted" .Send End With |