Parent

Rubyipmi::Ipmitool::Connection

Attributes

debug[RW]
options[RW]

Public Class Methods

new(user, pass, host,debug_value=false) click to toggle source
# File lib/rubyipmi/ipmitool/connection.rb, line 19
def initialize(user, pass, host,debug_value=false)
  @debug = debug_value
  @options = Rubyipmi::ObservableHash.new
  raise("Must provide a host to connect to") unless host
  @options["H"] = host
  # Credentials can also be stored in the freeipmi configuration file
  # So they are not required
  @options["U"] = user if user
  @options["P"] = pass if pass
  # default to IPMI 2.0 communication, this means that older devices will not work
  # Those old servers should be recycled by now, as the 1.0, 1.5 spec came out in 2005ish and is 2013.
  #@options["I"] = "lanplus"

  #getWorkArounds
end

Public Instance Methods

bmc() click to toggle source
# File lib/rubyipmi/ipmitool/connection.rb, line 43
def bmc
  @bmc ||= Rubyipmi::Ipmitool::Bmc.new(@options)
end
chassis() click to toggle source
# File lib/rubyipmi/ipmitool/connection.rb, line 51
def chassis
  @chassis ||= Rubyipmi::Ipmitool::Chassis.new(@options)
end
fru() click to toggle source
# File lib/rubyipmi/ipmitool/connection.rb, line 35
def fru
  @fru ||= Rubyipmi::Ipmitool::Fru.new(@options)
end
get_diag() click to toggle source
# File lib/rubyipmi/ipmitool/connection.rb, line 55
def get_diag
  data = {}
  data['provider'] = provider
  if @fru
    data['frus'] = @fru.getfrus
  end
  if @sensors
    data['sensors'] = @sensors.getsensors
  end
  if @bmc
    data['bmc_info'] = @bmc.info
  end
end
provider() click to toggle source
# File lib/rubyipmi/ipmitool/connection.rb, line 39
def provider
  return "ipmitool"
end
sensors() click to toggle source
# File lib/rubyipmi/ipmitool/connection.rb, line 47
def sensors
  @sensors ||= Rubyipmi::Ipmitool::Sensors.new(@options)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.