I have a problem. I use OPSView server and the Opsview Windows Agent (last version).
I don't succeed to pass argument to my powershell script.
When I use this line in the .ini file:
check_DFSR_Backlog = cmd /c echo scripts\check_DFSR_Backlog.ps1 $ARG1$ ; exit($lastexitcode) | powershell.exe -command -
And check_nrpe -H $HOSTADDRESS$ -c check_DFSR_Backlog -a FolderName in the OPSView
The result is of args is $ . I have try with quote, double quote... always the same $
In the log :
2016-11-23 13:59:18: debug:NSClient++.cpp:1143: Injecting: check_DFSR_Backlog: Foldername
2016-11-23 13:59:19: debug:NSClient++.cpp:1179: Injected Result: OK '$
2016-11-23 13:59:19: debug:NSClient++.cpp:1180: Injected Performance Result: ''
I have tried with : check_DFSR_Backlog = cmd /c echo scripts\check_DFSR_Backlog.ps1 foldername ; exit($lastexitcode) | powershell.exe -command - and I have args -> foldername in my powershell and so in monitoring windows.
Is there someome that had the same ? or know to fix this