XI for Windows 2008 R2: how to check specific account logon
XI for Windows 2008 R2: how to check specific account logon
Hello XI support
Please advice how to check if specific account is logged on to the server (and remain logged on)
- so that we monitor and alert if account logged off (some application account)
- Windows 2008 R2
/Dimitri
Please advice how to check if specific account is logged on to the server (and remain logged on)
- so that we monitor and alert if account logged off (some application account)
- Windows 2008 R2
/Dimitri
Re: XI for Windows 2008 R2: how to check specific account lo
Are you talking about monitoring a service or a process? Can you give us a specific example?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: XI for Windows 2008 R2: how to check specific account lo
Monitor account (user) XYZ logged to the server, alert when logs off (some applications require this kind to "running" RDP session by certain accountlmiltchev wrote:Are you talking about monitoring a service or a process? Can you give us a specific example?
Re: XI for Windows 2008 R2: how to check specific account lo
I found this script, would it work for you? https://exchange.nagios.org/directory/P ... er/details
Former Nagios Employee
Re: XI for Windows 2008 R2: how to check specific account lo
rkennedy wrote:I found this script, would it work for you? https://exchange.nagios.org/directory/P ... er/details
Partially. Followed instructions
ini looks this way:
[/settings/external scripts/scripts]
check_user=cmd /c echo scripts\\check_user.ps1 ZZTP-APL01 RES svc_ZZZsrv1; exit $LastExitCode | powershell.exe -command-
XI end shows this:
OK Missing expression after unary operator '-'.
At line:1 char:2
+ - <<<< command-
+ CategoryInfo : ParserError: (-:String) [], ParentContainsErrorR
ecordException
+ FullyQualifiedErrorId : MissingExpressionAfterOperator
Re: XI for Windows 2008 R2: how to check specific account lo
Can you try changing it to be (space after command but before the -) -
Let us know if that helps.
Code: Select all
check_user=cmd /c echo scripts\\check_user.ps1 ZZTP-APL01 RES svc_ZZZsrv1; exit $LastExitCode | powershell.exe -command -
Former Nagios Employee
Re: XI for Windows 2008 R2: how to check specific account lo
This is what I get when trying to "test" from XI GUI:rkennedy wrote:Can you try changing it to be (space after command but before the -) -Let us know if that helps.Code: Select all
check_user=cmd /c echo scripts\\check_user.ps1 ZZTP-APL01 RES svc_ZZZsrv1; exit $LastExitCode | powershell.exe -command -
COMMAND: /usr/local/nagios/libexec/check_nrpe -H 10.72.129.49 -t 30 -c check_user
OUTPUT: File C:\Program Files\NSClient++\scripts\check_user.ps1 cannot be loaded becaus
e the execution of scripts is disabled on this system. Please see "get-help abo
ut_signing" for more details.
At line:1 char:24
+ scripts\\check_user.ps1 <<<< DEHP-APL01 RES svc_stahlsrv1; exit $LastExitCod
INI file attached.
e
+ CategoryInfo : NotSpecified: (:) [], PSSecurityException
+ FullyQualifiedErrorId : RuntimeException
You do not have the required permissions to view the files attached to this post.
Re: XI for Windows 2008 R2: how to check specific account lo
Are you allowed to run PS scrips on this system? Can you open a powershell terminal, type the following command, and show the output?OUTPUT: File C:\Program Files\NSClient++\scripts\check_user.ps1 cannot be loaded becaus
e the execution of scripts is disabled on this system. Please see "get-help abo
ut_signing" for more details.
Code: Select all
Get-ExecutionPolicyBe sure to check out our Knowledgebase for helpful articles and solutions!
Re: XI for Windows 2008 R2: how to check specific account lo
You right: restrictedlmiltchev wrote:Are you allowed to run PS scrips on this system? Can you open a powershell terminal, type the following command, and show the output?OUTPUT: File C:\Program Files\NSClient++\scripts\check_user.ps1 cannot be loaded becaus
e the execution of scripts is disabled on this system. Please see "get-help abo
ut_signing" for more details.
Code: Select all
Get-ExecutionPolicy
Re: XI for Windows 2008 R2: how to check specific account lo
Is that something you're going to be able to fix?
Former Nagios Employee.
me.
me.