Learn more  » Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Bower components Debian packages RPM packages NuGet packages

vistahigherlearning / logstash   deb

Repository URL to install this package:

/ opt / logstash / vendor / bundle / jruby / 1.9 / gems / snmp-1.1.1 / examples / get.rb

require 'snmp'

host = ARGV[0] || 'localhost'

manager = SNMP::Manager.new(:Host => host, :Port => 161)
response = manager.get(["sysDescr.0", "sysName.0"])
response.each_varbind { |vb| puts vb.to_s }