ZABBIX Forums  
  #21  
Old 27-05-2015, 15:50
sersad sersad is offline
Senior Member
 
Join Date: May 2009
Location: Russia
Posts: 500
Default

Diwahar
https://www.zabbix.com/documentation...ce/trigger/get
In Request add "selectFunctions": "extend"
The reply will contain an array "functions":"itemid"

/history.php?action=showgraph&itemids[]="itemid"
Reply With Quote
  #22  
Old 05-06-2015, 07:58
Diwahar Diwahar is offline
Junior Member
 
Join Date: Sep 2014
Posts: 15
Default Zabbix Trigger Dashboard

@sersad: is this is crct?


$triggers = $api->triggerGet(array(
'output' => array(
'priority',
'description',
'lastChangeSince'),
'selectHosts' => array('hostid'),
'selectFunctions' => array('itemid'),
'groupids' => $groupIds,
'expandDescription' => 1,
'only_true' => 1,
'monitored' => 1,
'withLastEventUnacknowledged' => 1,
'sortfield' => 'priority',
'sortorder' => 'DESC'
));

foreach($triggers as $trigger) {
foreach($trigger->hosts as $host) {
$hostTriggers[$host->hostid][] = $trigger;
foreach($trigger->items as $item) {
$itemTriggers[$item->itemid][] = $trigger;
}
}
}

plz, can u help me in this?
Reply With Quote
  #23  
Old 05-06-2015, 10:18
Diwahar Diwahar is offline
Junior Member
 
Join Date: Sep 2014
Posts: 15
Default

@sersad: i got it... works fine now.

Thanks



Quote:
Originally Posted by Diwahar View Post
@sersad: is this is crct?


$triggers = $api->triggerGet(array(
'output' => array(
'priority',
'description',
'lastChangeSince'),
'selectHosts' => array('hostid'),
'selectFunctions' => array('itemid'),
'groupids' => $groupIds,
'expandDescription' => 1,
'only_true' => 1,
'monitored' => 1,
'withLastEventUnacknowledged' => 1,
'sortfield' => 'priority',
'sortorder' => 'DESC'
));

foreach($triggers as $trigger) {
foreach($trigger->hosts as $host) {
$hostTriggers[$host->hostid][] = $trigger;
foreach($trigger->items as $item) {
$itemTriggers[$item->itemid][] = $trigger;
}
}
}

plz, can u help me in this?
Reply With Quote
  #24  
Old 05-06-2015, 19:23
Diwahar Diwahar is offline
Junior Member
 
Join Date: Sep 2014
Posts: 15
Default Zabbix Trigger Dashboard

@sersad:

Any idea how to get the triggers using templates??


Quote:
Originally Posted by sersad View Post
Diwahar
https://www.zabbix.com/documentation...ce/trigger/get
In Request add "selectFunctions": "extend"
The reply will contain an array "functions":"itemid"

/history.php?action=showgraph&itemids[]="itemid"
Reply With Quote
  #25  
Old 08-06-2015, 10:59
sersad sersad is offline
Senior Member
 
Join Date: May 2009
Location: Russia
Posts: 500
Default

find a trigger from a template?
Reply With Quote
  #26  
Old 08-06-2015, 12:19
Diwahar Diwahar is offline
Junior Member
 
Join Date: Sep 2014
Posts: 15
Default Zabbix Trigger Dashboard

@sersad : Yes


Quote:
Originally Posted by sersad View Post
find a trigger from a template?
Reply With Quote
  #27  
Old 09-06-2015, 16:36
waardd waardd is offline
Member
 
Join Date: Aug 2014
Posts: 72
Default

Bumping my problem

Like mentioned earlier i only see a date/time and my pagename and nothing else.
I'm using zabbix 1.8.20 and this is the php page i call.

Is there a different version of the php dashboard i have to use or the ZabbixApi's?
Reply With Quote
  #28  
Old 09-06-2015, 17:32
incama incama is offline
Junior Member
 
Join Date: Jan 2015
Location: Maastricht
Posts: 13
Default

Quote:
Originally Posted by waardd View Post
Bumping my problem

Like mentioned earlier i only see a date/time and my pagename and nothing else.
I'm using zabbix 1.8.20 and this is the php page i call.

Is there a different version of the php dashboard i have to use or the ZabbixApi's?
Hi Waard,

I never tested the dashboard in 1.8, but I know I did experienced some issues when upgrading from 2.2 to 2.4. All it took was updating the php api files to a newer version. Don't know if there is an older php api version you can download.
Reply With Quote
  #29  
Old 10-06-2015, 08:35
waardd waardd is offline
Member
 
Join Date: Aug 2014
Posts: 72
Default

Quote:
Originally Posted by incama View Post
Hi Waard,

I never tested the dashboard in 1.8, but I know I did experienced some issues when upgrading from 2.2 to 2.4. All it took was updating the php api files to a newer version. Don't know if there is an older php api version you can download.
Could it be that the way you get the information in the API call is different from the way to get it in 1.8?
Reply With Quote
  #30  
Old 10-06-2015, 10:06
incama incama is offline
Junior Member
 
Join Date: Jan 2015
Location: Maastricht
Posts: 13
Default

Quote:
Originally Posted by waardd View Post
Could it be that the way you get the information in the API call is different from the way to get it in 1.8?
Although I'm not a Zabbix Api expert, it is indeed what I think. Don't know if someone can share a light on this?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 03:39.