mirror of
https://github.com/munin-monitoring/contrib.git
synced 2018-11-08 00:59:34 +01:00
Merge pull request #99 from lkarsten/master
munin-node-from-hell: Added three plugins: config+fetch fails, config work but fetch fails, works but omits .value on a ds.
This commit is contained in:
commit
bda7b6ea64
@ -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…
Reference in New Issue
Block a user