vavere / zabbix-w3wp

Zabbix IIS 7 Worker Process Template
14 stars 8 forks source link

Issues with calling the item prototypes #1

Open blagoycho opened 10 years ago

blagoycho commented 10 years ago

Hi,

I am trying to use the zabbix-w3wp template to measure the IIS worker processes. Everything appears to alright, discovery script is working - discovers the application pools and return valid JSON (at least in the zabbix_agentd.log file) but the second script (w3wp-wmi.js) is not executed on the host?!?!?

Just for test i added to the item prototypes a system.run key (system.run["cscript /Nologo \"C:\Program Files\Zabbix\w3wp-wmi.js\" {#WPNAME} PercentProcessorTime"]) and is not executed again.

On the host itself I tried to run both .js scripts with the necessary parameters and they work fine. The problem is that Zabbix server is not requesting execution of the item prototypes even when discovery of the application pools is done OK

Please give us a hint what to tweak further ... I am out of any decent options!

Regards, Blagoy

vavere commented 10 years ago

i'm not a big zabbix knower

but to understand what is going on logging should be switched on

in file C:\Program Files\Zabbix\zabbix_agentd.conf add lines:

LogFile=c:\zabbix_agentd.log DebugLevel=4

and restart agent service

lauris

blagoycho commented 10 years ago

Hi,

Thank you for the follow up. I have those settings already in my zabbix agent. In the log file I can see the discovery script run and returning nice piece of JSON with list of the active application pools. But the WMI script is not executed afterwards.

Blagoy

vavere commented 10 years ago

i tried the following steps

  1. %windir%\system32\inetsrv\appcmd.exe list wp and read some {wpname} from list
  2. cd C:\Program Files\Zabbix\
  3. cscript /nologo w3wp-wmi.js {wpname} HandleCount where substitute {wpname} from first step

lauris

blagoycho commented 10 years ago

Hi Lauris,

Everything on the host side is work when i execute it manually (both discovery and WMI querying). My problem is that Zabbix server is not querying the application pools after they weer discovered. I do not see an entry in the zabbix agent log file for it.

We are running Zabbix version 2.0.2 maybe that is the problem. Somewhere in the internet I read about your template and person is stating that it works on Zabbix 2.0.5.

Regards, Blagoy

bertubrio commented 9 years ago

Hi¡

I'm trying to do this on Zabbix 2.4, but i'm getting this error:

cscript w3-wp-discovery.js(1, 1) Microsoft JScript runtime error: 'Wscript' is undefined

What i'm doing wrong?

Thanks in advance.

Regards.