mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-22 02:51:03 +00:00
Add plugins that fail on the node.
This commit is contained in:
parent
accf47f9a0
commit
32f9909e6d
2 changed files with 33 additions and 1 deletions
|
@ -8,7 +8,7 @@ pluginprofile = basic
|
||||||
port = 4001
|
port = 4001
|
||||||
|
|
||||||
[pluginprofile:basic]
|
[pluginprofile:basic]
|
||||||
plugins = graph_area
|
plugins = graph_area, failing_plugin, failing_plugin2, failing_plugin3
|
||||||
|
|
||||||
[base]
|
[base]
|
||||||
# when building an example config with --muninconf, what hostname to output.
|
# when building an example config with --muninconf, what hostname to output.
|
||||||
|
|
|
@ -110,6 +110,38 @@ class always_critical(always_warning):
|
||||||
return self.conftext.replace("LEVEL","critical")
|
return self.conftext.replace("LEVEL","critical")
|
||||||
modules["always_critical"] = always_critical()
|
modules["always_critical"] = always_critical()
|
||||||
|
|
||||||
|
class failing_plugin(MuninPlugin):
|
||||||
|
"A really broken plugin"
|
||||||
|
def fetch(self, conf):
|
||||||
|
return "# Bad exit"
|
||||||
|
|
||||||
|
def config(self, conf):
|
||||||
|
return "# Bad exit"
|
||||||
|
modules["failing_plugin"] = failing_plugin()
|
||||||
|
|
||||||
|
class failing_plugin2(MuninPlugin):
|
||||||
|
def fetch(self, conf):
|
||||||
|
return "# Bad exit"
|
||||||
|
|
||||||
|
def config(self, conf):
|
||||||
|
return """graph_title Config works, fetch fails
|
||||||
|
graph_vlabel Level
|
||||||
|
graph_category failing
|
||||||
|
generic.label generic_label_here
|
||||||
|
generic.info never_really_used"""
|
||||||
|
modules["failing_plugin2"] = failing_plugin2()
|
||||||
|
|
||||||
|
class failing_plugin3(MuninPlugin):
|
||||||
|
def config(self, conf):
|
||||||
|
return """graph_title A plugin with two dses but only fetch value for one
|
||||||
|
graph_args --base 1000 -l 0
|
||||||
|
fivemin.label 1 minute load
|
||||||
|
onemin.label 5 minute load"""
|
||||||
|
def fetch(self, conf):
|
||||||
|
return "onemin.value 1"
|
||||||
|
modules["failing_plugin3"] = failing_plugin3()
|
||||||
|
|
||||||
|
|
||||||
class graph_area(MuninPlugin):
|
class graph_area(MuninPlugin):
|
||||||
"A plugin that uses STACK and AREA. From proc_pri. Use: testing the grapher"
|
"A plugin that uses STACK and AREA. From proc_pri. Use: testing the grapher"
|
||||||
def fetch(self, conf):
|
def fetch(self, conf):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue