summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authordevicenull <devicenull@users.noreply.github.com>2017-01-11 12:58:05 -0500
committerGitHub <noreply@github.com>2017-01-11 12:58:05 -0500
commit58cb58dd9b00b84115cb7e547900cca90774292b (patch)
tree980064f62091dde0e757aa799ff94bd335966925 /lib
parentc5e25141e642b5c0156fb5dbcc5139461e3b112a (diff)
Ignore fan speed changes for ironware
Brocade ICX/FCX log fan speed changes like this: Fan ok, speed (auto): 1<->[[2]]<->3 Fan ok, speed (auto): [[1]]<->2<->3 Remove the current fan speed from the configuration to prevent lots of useless changes from being logged.
Diffstat (limited to 'lib')
-rw-r--r--lib/oxidized/model/ironware.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/oxidized/model/ironware.rb b/lib/oxidized/model/ironware.rb
index ade8b44..e1c6da1 100644
--- a/lib/oxidized/model/ironware.rb
+++ b/lib/oxidized/model/ironware.rb
@@ -34,6 +34,7 @@ class IronWare < Oxidized::Model
cfg.gsub! /(^((.*)Current temp(.*))$)/, '' #remove unwanted lines current temperature
cfg.gsub! /Speed = [A-Z-]{2,6} \(\d{2,3}\%\)/, '' #remove unwanted lines Speed Fans
cfg.gsub! /current speed is [A-Z]{2,6} \(\d{2,3}\%\)/, ''
+ cfg.gsub! /([\[]*)1([\]]*)<->([\[]*)2([\]]*)<->([\[]*)3([\]]*)/, ''
cfg.gsub! /\d{2}\.\d deg-C/, 'XX.X deg-C'
if cfg.include? "TEMPERATURE"
sc = StringScanner.new cfg