Hey all... next phase of troubleshooting my Powershell script problem...
I have some custom User Parameters defined in my Agent config file. These parameters are calling Windows Powershell scripts that I created.
Example UserParameter in the config file:
When I activate the Userparameter manually:
... that results in log entries like this:
When I trigger an "Action" on the Zabbix server, which in turn calls the remote Agent on this Host:
I have some custom User Parameters defined in my Agent config file. These parameters are calling Windows Powershell scripts that I created.
Example UserParameter in the config file:
HTML Code:
UserParameter=test.testParams_ps,powershell -noninteractive "C:\Program Files\Zabbix Agent\scripts\Testing\testParams3.ps1"
When I activate the Userparameter manually:
HTML Code:
> zabbix_get -s 127.0.0.1 -k fmsadmin.testParams_ps
HTML Code:
8436:20200429:191306.168 Requested [test.testParams_ps] 8436:20200429:191306.486 EXECUTE_STR() command:'powershell -noninteractive -file "C:\Program Files\Zabbix Agent\scripts\Testing\testParams.ps1"' len:54 cmd_result:'Executing PS script ' 8436:20200429:191306.486 Sending back [Executing PS script from source = Zabbix server action]
When I trigger an "Action" on the Zabbix server, which in turn calls the remote Agent on this Host:
HTML Code:
7524:20200429:191400.494 Requested [system.run[\Program Files\Zabbix Agent\zabbix_get -s 127.0.0.1 -p 10050 -k test.testParams_ps,nowait]] 7524:20200429:191400.495 Executing command '\Program Files\Zabbix Agent\zabbix_get -s 127.0.0.1 -p 10050 -k test.testParams_ps' 7524:20200429:191400.495 zbx_execute_nowait(): executing [cmd /C "\Program Files\Zabbix Agent\zabbix_get -s 127.0.0.1 -p 10050 -k test.testParams_ps"] 7524:20200429:191400.496 Sending back [1]
Comment