diff options
Diffstat (limited to 'munin/ipmi_sensor_')
-rwxr-xr-x | munin/ipmi_sensor_ | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/munin/ipmi_sensor_ b/munin/ipmi_sensor_ index a4866a2..bda92c8 100755 --- a/munin/ipmi_sensor_ +++ b/munin/ipmi_sensor_ @@ -24,10 +24,13 @@ def bail_out(m) exit 1 end def normalize_sensor(s) - s.downcase.tr('^a-z0-9-', '_') + s = s.downcase + s = s.tr('-', 'M') + s = s.tr('+', 'P') + s.tr('^a-zA-Z0-9', '_') end def normalize_unit(s) - s.downcase.tr('^a-z0-9-', '_') + s.downcase.tr('^a-z0-9', '_') end def get_sensor_data data = [] |