PDA

View Full Version : Can't Re-create web scenario


frankcheong
12-01-2010, 08:49
I have encountered a strange problem with the following steps:-

Create a web scenario "WA" under host "HA".
Create a trigger "TA" under host "HA" for web scenario "WA".
Create an action "AA" under host "HA" based on trigger "TA".

Everything works fine.

Then I have delete the web scenario "WA".
I can't find the trigger "TA" under host "HA".
The condition for action "AA" become blank, I then delete action "AA" under host "HA".

Then I have create the web scenario with the same name "WA" under host "HB".
I tried to create trigger "TB" under host "HB" for web scenario "WA" but the UI complaint with "* No such monitored parameter ( web.test.fail[WA]) for host (HB)"
I tried to create an item under host "HB" with key "web.test.fail[WA]" but it complained that "* An item with the Key [web.test.fail[WA]] already exists for host [HB]. The key must be unique.", I know I don't need to do that and should not do that, but just would like to check if the key already exist which is the case. Wonder why I cannot create this trigger.

FYI, I have also tried to create the web scenario as WB or WC (another name) but it also failed with the same result. What could possibly be the cause? What should I do then?

frankcheong
15-01-2010, 08:54
Strange, I have deleted everything again and the same reports. I have step into the database and issue the following select statement and I can successfully found the record in the database ites:-

select * from items A, hosts B where A.hostid=B.hostid and B.host='HB';

What else should I check?

frankcheong
15-01-2010, 09:03
Finally I know what happened. I just copied the code from the Zabbix web monitoring documentation (http://www.zabbix.com/documentation/1.8/manual/web_monitoring).

Whereby the documentation have two errors.

1. {host: web.test.fail[Scenario]}.last(0)#0
The final } should be after the last zero which is
{host: web.test.fail[Scenario].last(0)#0}

2. There is a space between host: and web. which caused this error, the correct key should be :-
{host:web.test.fail[Scenario].last(0)#0}
instead.

Suggest to also correct the documentation.