sensu-plugins-check-lan 0.0.8 → 0.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3d163232350f464e2619b3a66a75413408279b8e
4
- data.tar.gz: 349daed6edc266ec7569322c513f08a6ff47037e
3
+ metadata.gz: bcc5167368ca6cf62ef1ab0144d59f5a62167d83
4
+ data.tar.gz: dd081d93b7c21ca44472f29e988b9946f8ee3beb
5
5
  SHA512:
6
- metadata.gz: 647ac02052cebeee85fe470c0cf4b00cee41a7ae3bbfe356204cda893f813f669888a423631e661af2f14ba6400c98499c2813d29104dae68b112b84a4f164b9
7
- data.tar.gz: 35b759505f51321ee42f0b0ac327ad0cd851987d43ac437ac3b81b739071cee405a38a86655b4634c1165f7dc34ed9e5b0c27e1cde5dcf89fc726e0607c07944
6
+ metadata.gz: 6fd2864cd7cf3c2462a52766765689e41708a5fb689ac2453922e90ae54f7f9ea09395d6a602a5f7ad7990ff051335b9ce4fea0510cc9633e30aaf8810b0caa8
7
+ data.tar.gz: 8de3a63c81eefc268fc94d9abf131bc2828829a5973b5cdb93b68efeb952de81a23a88cc3bdd33deb98215918b0f24b0d285a04ef90bd3bed163c701b6bf307a
@@ -3,7 +3,7 @@
3
3
  # check-lan
4
4
  #
5
5
  # DESCRIPTION:
6
- # This plugin uses checks (standalone) if a given ip is reachable and if it is not restarts the given interface.
6
+ # This plugin checks (standalone) if a given ip is reachable and if it is not restarts the given interface.
7
7
  # If this is not successfull this plugin reboots the client machine.
8
8
  #
9
9
  # OUTPUT:
@@ -44,22 +44,22 @@ class CheckLan < Sensu::Plugin::Check::CLI
44
44
 
45
45
  def run
46
46
 
47
- puts "ping #{IP_TO_PING} for checking conectivity..."
47
+ #puts "ping #{IP_TO_PING} for checking conectivity..."
48
48
  ping()
49
49
  if $?.exitstatus >= 1
50
- puts "#{INTERFACE} seems to be down, trying to bring it up..."
51
- puts "executing ifdown #{INTERFACE}"
50
+ #puts "#{INTERFACE} seems to be down, trying to bring it up..."
51
+ #puts "executing ifdown #{INTERFACE}"
52
52
  `sudo #{IFDOWN} #{INTERFACE} `
53
- puts "waiting 10 seconds to bring #{INTERFACE} up..."
53
+ #puts "waiting 10 seconds to bring #{INTERFACE} up..."
54
54
  `sleep 10`
55
- puts "executing ifup #{INTERFACE}"
55
+ #puts "executing ifup #{INTERFACE}"
56
56
  `sudo #{IFUP} #{INTERFACE}`
57
- puts "waiting 10 seconds to ping again..."
57
+ #puts "waiting 10 seconds to ping again..."
58
58
  `sleep 10`
59
- puts "ping server again..."
59
+ #puts "ping server again..."
60
60
  ping()
61
61
  if $?.exitstatus >= 1
62
- puts "#{INTERFACE} is still down, REBOOT to recover..."
62
+ #puts "#{INTERFACE} is still down, REBOOT to recover..."
63
63
  `sudo reboot`
64
64
  critical "REBOOT to recover"
65
65
  else
@@ -6,7 +6,7 @@ module SensuPluginsCheckLan
6
6
  module Version
7
7
  MAJOR = 0
8
8
  MINOR = 0
9
- PATCH = 8
9
+ PATCH = 9
10
10
 
11
11
  VER_STRING = [MAJOR, MINOR, PATCH].compact.join('.')
12
12
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sensu-plugins-check-lan
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Max