From f6bd0ee9158de10e75011783c087171898705ad0 Mon Sep 17 00:00:00 2001 From: yayogev Date: Wed, 6 Sep 2017 20:17:57 +0300 Subject: US2925 add monitoring of host pNIC in OVS - check_interface.py: renamed to check_pnic_ovs.py - check_interface.py: check changed to use 'ip link show' command - monitor.py: handle check name where object type contains underscore, specifically 'host_pnic' - monitor.py: refactored to work as class - monitoring_pnic.py: changed to handle either OVS or VPP - monitoring_check_handler.py: change to allow defining hard-coded check_type string for file_type naming - monitoring config templates: removed default handler Change-Id: Iad38fa108e9ceae18a7c94b3570a8d9b836a8632 Signed-off-by: yayogev --- app/install/db/monitoring_config_templates.json | 58 +++++++++++++++++-------- 1 file changed, 39 insertions(+), 19 deletions(-) (limited to 'app/install/db') diff --git a/app/install/db/monitoring_config_templates.json b/app/install/db/monitoring_config_templates.json index 3dbacae..9bddfa2 100644 --- a/app/install/db/monitoring_config_templates.json +++ b/app/install/db/monitoring_config_templates.json @@ -88,8 +88,7 @@ "base" ], "handlers" : [ - "default", - "file", + "file", "osdna-monitor" ] } @@ -150,7 +149,6 @@ }, "keepalive" : { "handlers" : [ - "default", "file" ] } @@ -218,8 +216,7 @@ "base" ], "handlers" : [ - "default", - "file", + "file", "osdna-monitor" ] } @@ -247,8 +244,7 @@ "base" ], "handlers" : [ - "default", - "file", + "file", "osdna-monitor" ] } @@ -270,8 +266,7 @@ "base" ], "handlers" : [ - "default", - "file", + "file", "osdna-monitor" ] } @@ -306,8 +301,7 @@ "base" ], "handlers" : [ - "default", - "file", + "file", "osdna-monitor" ] } @@ -316,34 +310,61 @@ "monitoring_system" : "sensu", "type" : "client_check_link_vnic-vconnector.json" }, -{ +{ "side" : "client", "order" : "1", "condition" : { "mechanism_drivers" : [ - "VPP" + "OVS" ] }, "config" : { "checks" : { "{objtype}_{objid}" : { "interval" : 15, - "command" : "check_pnic_vpp.py", + "command" : "check_pnic_ovs.py {local_name}", "standalone" : true, "type": "metric", "subscribers" : [ "base" ], "handlers" : [ - "default", - "file", + "file", "osdna-monitor" ] } } }, "monitoring_system" : "sensu", - "type" : "client_check_pnic.json" + "type" : "client_check_host_pnic_ovs.json" +}, +{ + "side" : "client", + "order" : "1", + "condition" : { + "mechanism_drivers" : [ + "VPP" + ] + }, + "config" : { + "checks" : { + "{objtype}_{objid}" : { + "interval" : 15, + "command" : "check_pnic_vpp.py", + "standalone" : true, + "type": "metric", + "subscribers" : [ + "base" + ], + "handlers" : [ + "file", + "osdna-monitor" + ] + } + } + }, + "monitoring_system" : "sensu", + "type" : "client_check_host_pnic_vpp.json" }, { "side" : "client", @@ -365,8 +386,7 @@ "base" ], "handlers" : [ - "default", - "file", + "file", "osdna-monitor" ] } -- cgit 1.2.3-korg