From 4eb1eb2cf9ae0701b6d51a1601b4049e825791d8 Mon Sep 17 00:00:00 2001 From: Saku Ytti Date: Sat, 30 Aug 2014 11:42:45 +0300 Subject: Remove ntp clock-period completely emj complained that it sometimes pops in, sometimes pops out. I guess really no point having it there. --- lib/oxidized/model/ios.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/oxidized/model/ios.rb b/lib/oxidized/model/ios.rb index d2b4996..6fa3c5c 100644 --- a/lib/oxidized/model/ios.rb +++ b/lib/oxidized/model/ios.rb @@ -37,9 +37,9 @@ class IOS < Oxidized::Model end cmd 'show running-config' do |cfg| - cfg = cfg.each_line.to_a[3..-1].join + cfg = cfg.each_line.to_a[3..-1] + cfg = cfg.reject { |line| line.match /^ntp clock-period / }.join cfg.gsub! /^Current configuration : [^\n]*\n/, '' - cfg.sub! /^(ntp clock-period).*/, '! \1' cfg.gsub! /^\ tunnel\ mpls\ traffic-eng\ bandwidth[^\n]*\n*( (?:\ [^\n]*\n*)* tunnel\ mpls\ traffic-eng\ auto-bw)/mx, '\1' -- cgit v1.2.1