]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/zabbix: Fix raw_bytes_used key name 28058/head
authorDmitriy Rabotjagov <dmitriy.r@sitevalley.com>
Fri, 10 May 2019 12:18:58 +0000 (15:18 +0300)
committerDmitriy Rabotjagov <dmitriy.r@sitevalley.com>
Tue, 28 May 2019 10:10:49 +0000 (13:10 +0300)
This patch fixes raw_bytes_used key which was renamed to stored_raw.
Also added key percent_used and fixed zabbix template to be fully
compatible with zabbix 3.0

Fixes: https://tracker.ceph.com/issues/39644
Signed-off-by: Dmitriy Rabotjagov <noonedeadpunk@ya.ru>
PendingReleaseNotes
src/pybind/mgr/zabbix/module.py
src/pybind/mgr/zabbix/zabbix_template.xml

index 6941d48843b408fade919c3c05a61542121d2178..c1cff457546ebb6d5b5d9863cbb9895befbf815b 100644 (file)
@@ -65,3 +65,8 @@
   was 'wait_backfill' and the correct name is 'backfill_wait'.
   Update your Zabbix template accordingly so that it accepts the
   new key being send to Zabbix.
+
+* zabbix plugin for ceph manager now includes osd and pool
+  discovery. Update of zabbix_template.xml is needed
+  to receive per-pool (read/write throughput, diskspace usage)
+  and per-osd (latency, status, pgs) statistics
index 53101818872682a40a2506331a3ea2ee79c64ce1..3fbe86ec7d476792fa406273b6e15e11c24fd925 100644 (file)
@@ -206,7 +206,8 @@ class Module(MgrModule):
             data['[{0},rd_ops]'.format(pool['name'])] = pool['stats']['rd']
             data['[{0},wr_ops]'.format(pool['name'])] = pool['stats']['wr']
             data['[{0},bytes_used]'.format(pool['name'])] = pool['stats']['bytes_used']
-            data['[{0},raw_bytes_used]'.format(pool['name'])] = pool['stats']['raw_bytes_used']
+            data['[{0},stored_raw]'.format(pool['name'])] = pool['stats']['stored_raw']
+            data['[{0},percent_used]'.format(pool['name'])] = pool['stats']['percent_used']
 
         data['wr_ops'] = wr_ops
         data['rd_ops'] = rd_ops
index e2a8344ec81f4a8aaf2147d17ae73eff4e6c3f02..17bff78234c096ea5e37db71a9c6e6f763a5d463 100644 (file)
                     <snmpv3_authpassphrase/>
                     <snmpv3_privprotocol>0</snmpv3_privprotocol>
                     <snmpv3_privpassphrase/>
+                    <delay_flex/>
                     <params/>
                     <ipmi_sensor/>
                     <authtype>0</authtype>
                             <name>[osd.{#OSD}] OSD in</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[osd.{#OSD},in]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[osd.{#OSD}] OSD PGs</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[osd.{#OSD},num_pgs]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[osd.{#OSD}] OSD fill</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[osd.{#OSD},osd_fill]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[osd.{#OSD}] OSD latency apply</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[osd.{#OSD},osd_latency_apply]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[osd.{#OSD}] OSD latency commit</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[osd.{#OSD},osd_latency_commit]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[osd.{#OSD}] OSD up</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[osd.{#OSD},up]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                     </item_prototypes>
                     <trigger_prototypes>
                         <trigger_prototype>
                             <expression>{ceph-mgr Zabbix module:ceph.[osd.{#OSD},up].last()}=0</expression>
-                            <recovery_mode>0</recovery_mode>
-                            <recovery_expression/>
                             <name>Ceph OSD osd.{#OSD} is DOWN</name>
-                            <correlation_mode>0</correlation_mode>
-                            <correlation_tag/>
                             <url/>
                             <status>0</status>
                             <priority>2</priority>
                             <description/>
                             <type>0</type>
-                            <manual_close>0</manual_close>
                             <dependencies/>
-                            <tags/>
                         </trigger_prototype>
                         <trigger_prototype>
                             <expression>{ceph-mgr Zabbix module:ceph.[osd.{#OSD},osd_fill].last()}&gt;={ceph-mgr Zabbix module:ceph.osd_full_ratio.last()}</expression>
-                            <recovery_mode>0</recovery_mode>
-                            <recovery_expression/>
                             <name>Ceph OSD osd.{#OSD} is full: {ITEM.VALUE}%</name>
-                            <correlation_mode>0</correlation_mode>
-                            <correlation_tag/>
                             <url/>
                             <status>0</status>
                             <priority>4</priority>
                             <description/>
                             <type>0</type>
-                            <manual_close>0</manual_close>
                             <dependencies/>
-                            <tags/>
                         </trigger_prototype>
                         <trigger_prototype>
                             <expression>{ceph-mgr Zabbix module:ceph.[osd.{#OSD},osd_fill].last()}&gt;={ceph-mgr Zabbix module:ceph.osd_nearfull_ratio.last()}</expression>
-                            <recovery_mode>0</recovery_mode>
-                            <recovery_expression/>
                             <name>Ceph OSD osd.{#OSD} is near full: {ITEM.VALUE}%</name>
-                            <correlation_mode>0</correlation_mode>
-                            <correlation_tag/>
                             <url/>
                             <status>0</status>
                             <priority>2</priority>
                             <description/>
                             <type>0</type>
-                            <manual_close>0</manual_close>
                             <dependencies/>
-                            <tags/>
                         </trigger_prototype>
                     </trigger_prototypes>
                     <graph_prototypes/>
                     <host_prototypes/>
-                    <jmx_endpoint/>
                 </discovery_rule>
                 <discovery_rule>
                     <name>Ceph pool discovery</name>
                     <snmpv3_authpassphrase/>
                     <snmpv3_privprotocol>0</snmpv3_privprotocol>
                     <snmpv3_privpassphrase/>
+                    <delay_flex/>
                     <params/>
                     <ipmi_sensor/>
                     <authtype>0</authtype>
                             <name>[{#POOL}] Pool Used</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[{#POOL},bytes_used]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[{#POOL}] Pool RAW Used</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
-                            <key>ceph.[{#POOL},raw_bytes_used]</key>
+                            <key>ceph.[{#POOL},stored_raw]</key>
                             <delay>0</delay>
                             <history>90</history>
                             <trends>365</trends>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
+                            <authtype>0</authtype>
+                            <username/>
+                            <password/>
+                            <publickey/>
+                            <privatekey/>
+                            <port/>
+                            <description/>
+                            <inventory_link>0</inventory_link>
+                            <applications/>
+                            <valuemap/>
+                            <logtimefmt/>
+                            <application_prototypes>
+                                <application_prototype>
+                                    <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
+                                </application_prototype>
+                            </application_prototypes>
+                        </item_prototype>
+                        <item_prototype>
+                            <name>[{#POOL}] Pool Percent Used</name>
+                            <type>2</type>
+                            <snmp_community/>
+                            <multiplier>0</multiplier>
+                            <snmp_oid/>
+                            <key>ceph.[{#POOL},percent_used]</key>
+                            <delay>0</delay>
+                            <history>90</history>
+                            <trends>365</trends>
+                            <status>0</status>
+                            <value_type>3</value_type>
+                            <allowed_hosts/>
+                            <units>%</units>
+                            <delta>0</delta>
+                            <snmpv3_contextname/>
+                            <snmpv3_securityname/>
+                            <snmpv3_securitylevel>0</snmpv3_securitylevel>
+                            <snmpv3_authprotocol>0</snmpv3_authprotocol>
+                            <snmpv3_authpassphrase/>
+                            <snmpv3_privprotocol>0</snmpv3_privprotocol>
+                            <snmpv3_privpassphrase/>
+                            <formula>1</formula>
+                            <delay_flex/>
+                            <params/>
+                            <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing/>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[{#POOL}] Pool Read bandwidth</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[{#POOL},rd_bytes]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing>
-                                <step>
-                                    <type>10</type>
-                                    <params/>
-                                </step>
-                            </preprocessing>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[{#POOL}] Pool Read operations</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[{#POOL},rd_ops]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing>
-                                <step>
-                                    <type>10</type>
-                                    <params/>
-                                </step>
-                            </preprocessing>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[{#POOL}] Pool Write bandwidth</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[{#POOL},wr_bytes]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing>
-                                <step>
-                                    <type>10</type>
-                                    <params/>
-                                </step>
-                            </preprocessing>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                         <item_prototype>
                             <name>[{#POOL}] Pool Write operations</name>
                             <type>2</type>
                             <snmp_community/>
+                            <multiplier>0</multiplier>
                             <snmp_oid/>
                             <key>ceph.[{#POOL},wr_ops]</key>
                             <delay>0</delay>
                             <delay_flex/>
                             <params/>
                             <ipmi_sensor/>
+                            <data_type>0</data_type>
                             <authtype>0</authtype>
                             <username/>
                             <password/>
                             <applications/>
                             <valuemap/>
                             <logtimefmt/>
-                            <preprocessing>
-                                <step>
-                                    <type>10</type>
-                                    <params/>
-                                </step>
-                            </preprocessing>
-                            <jmx_endpoint/>
                             <application_prototypes>
                                 <application_prototype>
                                     <name>Ceph CRUSH [{#CRUSH_RULE}]</name>
                                 </application_prototype>
                             </application_prototypes>
-                            <master_item_prototype/>
                         </item_prototype>
                     </item_prototypes>
                     <trigger_prototypes/>
                     <graph_prototypes/>
                     <host_prototypes/>
-                    <jmx_endpoint/>
                 </discovery_rule>
             </discovery_rules>
             <macros/>