Skip to content

Commit

Permalink
Merge pull request #26 from rpsedlak/integration
Browse files Browse the repository at this point in the history
Release 1.0.2
  • Loading branch information
rpsedlak committed Dec 22, 2015
2 parents 889900c + abfcd27 commit f8f658a
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 8 deletions.
4 changes: 4 additions & 0 deletions ReleaseNotes.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release notes

## Release 1.0.2 - 12/21/2015
* #24 - Fixed container memory % report for Ubuntu
* #23 - Fixed false "down" report for Ubuntu

## Release 1.0.1 - 12/21/2015
* #20 - Changed collection delay for docker version
* #18 - Implemented WARNING trigger for paused containers
Expand Down
49 changes: 44 additions & 5 deletions ZabbixDockerTemplate.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>2.0</version>
<date>2015-12-21T20:59:49Z</date>
<date>2015-12-22T01:04:01Z</date>
<groups>
<group>
<name>Templates</name>
Expand Down Expand Up @@ -143,12 +143,51 @@
<valuemap/>
</item>
<item>
<name>Docker Daemons Running</name>
<name>Docker Daemons Running (CentOS)</name>
<type>0</type>
<snmp_community/>
<multiplier>0</multiplier>
<snmp_oid/>
<key>docker.running</key>
<key>docker.running.centos</key>
<delay>60</delay>
<history>90</history>
<trends>365</trends>
<status>0</status>
<value_type>3</value_type>
<allowed_hosts/>
<units/>
<delta>0</delta>
<snmpv3_securityname/>
<snmpv3_securitylevel>0</snmpv3_securitylevel>
<snmpv3_authpassphrase/>
<snmpv3_privpassphrase/>
<formula>1</formula>
<delay_flex/>
<params/>
<ipmi_sensor/>
<data_type>0</data_type>
<authtype>0</authtype>
<username/>
<password/>
<publickey/>
<privatekey/>
<port/>
<description>The number of docker process daemons running according to 'ps'</description>
<inventory_link>0</inventory_link>
<applications>
<application>
<name>Docker</name>
</application>
</applications>
<valuemap/>
</item>
<item>
<name>Docker Daemons Running (Ubuntu)</name>
<type>0</type>
<snmp_community/>
<multiplier>0</multiplier>
<snmp_oid/>
<key>docker.running.ubuntu</key>
<delay>60</delay>
<history>90</history>
<trends>365</trends>
Expand Down Expand Up @@ -5649,7 +5688,7 @@ last(&quot;docker.containers.running&quot;)</params>
</templates>
<triggers>
<trigger>
<expression>{Template App Docker:docker.running.last(0)}=0</expression>
<expression>{Template App Docker:docker.running.centos.last(0)}=0 &amp; {Template App Docker:docker.running.ubuntu.last(0)}=0</expression>
<name>Docker not running</name>
<url/>
<status>0</status>
Expand Down Expand Up @@ -5709,7 +5748,7 @@ last(&quot;docker.containers.running&quot;)</params>
</dependencies>
</trigger>
<trigger>
<expression>{Template App Docker:docker.running.last(0)}&gt;1</expression>
<expression>{Template App Docker:docker.running.centos.last(0)}&gt;1 | {Template App Docker:docker.running.ubuntu.last(0)}&gt;1</expression>
<name>More than 1 Docker daemon running</name>
<url/>
<status>0</status>
Expand Down
4 changes: 3 additions & 1 deletion userparameter_zabbixdocker.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@

UserParameter=docker.version, docker -v

UserParameter=docker.running, ps -ef | grep 'docker -d' | grep -v grep | wc -l
UserParameter=docker.running.centos, ps -ef | grep 'docker -d' | grep -v grep | wc -l

UserParameter=docker.running.ubuntu, ps -ef | grep 'docker daemon' | grep -v grep | wc -l

UserParameter=docker.containers.running, docker ps -q | wc -l

Expand Down
4 changes: 2 additions & 2 deletions zabbix-docker-stats.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ def lmem(data):
return value

def pmem(data):
pdata=data.split()
pmem_data=pdata[5].split('%')[0]
pdata=data.split('/')[1].split()
pmem_data=pdata[2].split('%')[0]
return pmem_data

def inet(data):
Expand Down

0 comments on commit f8f658a

Please sign in to comment.