Monday, June 25, 2012

impitools

POWER CONTROL

Power on server:

ipmitool -I lan -H 192.168.4.5 -U root -P calvin chassis power on

Power off server:

ipmitool -I lan -H 192.168.4.5 -U root -P calvin chassis power off


Server status:
ipmitool -I lan -H 192.168.4.5 -U root -P calvin chassis status


All chassis power Commands: 
status, on, off, cycle, reset, diag, soft 

SENSORS


List all sensors and their status:
ipmitool -I lan -H 192.168.4.5 -U root -P calvin sdr list

List temperature sensors and their status:
ipmitool -I lan -H 192.168.4.5 -U root -P calvin sdr type temperature

Get temperature from particular sensor id:
ipmitool -I lan -H 192.168.4.5 -U root -P calvin sdr get 'Ambient Temp'

All Sensor Types:    Temperature                 Voltage                 
    Current                     Fan                     
    Physical Security           Platform Security       
    Processor                   Power Supply            
    Power Unit                  Cooling Device          
    Other                       Memory                  
    Drive Slot / Bay            POST Memory Resize      
    System Firmwares            Event Logging Disabled  
    Watchdog                    System Event            
    Critical Interrupt          Button                  
    Module / Board              Microcontroller         
    Add-in Card                 Chassis                 
    Chip Set                    Other FRU               
    Cable / Interconnect        Terminator              
    System Boot Initiated       Boot Error              
    OS Boot                     OS Critical Stop        
    Slot / Connector            System ACPI Power State 
    Watchdog                    Platform Alert          
    Entity Presence             Monitor ASIC            
    LAN                         Management Subsystem Health
    Battery                     Session Audit           
    Version Change              FRU State



Other IPMI commands

Copy from http://www.openfusion.net/linux/ipmi_on_centos.html
 
# IPMI commands
ipmitool help
man ipmitool

# To check firmware version
ipmitool mc info
# To reset the management controller
ipmitool mc reset [ warm | cold ]

# Show field-replaceable-unit details
ipmitool fru print

# Show sensor output
ipmitool sdr list
ipmitool sdr type list
ipmitool sdr type Temperature
ipmitool sdr type Fan
ipmitool sdr type 'Power Supply'

# Chassis commands
ipmitool chassis status
ipmitool chassis identify [<interval>]   # turn on front panel identify light (default 15s)
ipmitool [chassis] power soft            # initiate a soft-shutdown via acpi
ipmitool [chassis] power cycle           # issue a hard power off, wait 1s, power on
ipmitool [chassis] power off             # issue a hard power off
ipmitool [chassis] power on              # issue a hard power on
ipmitool [chassis] power reset           # issue a hard reset

# Modify boot device for next reboot
ipmitool chassis bootdev pxe
ipmitool chassis bootdev cdrom
ipmitool chassis bootdev bios

# Logging
ipmitool sel info
ipmitool sel list
ipmitool sel elist                       # extended list (see manpage)
ipmitool sel clear

SOL - Serial over LAN (connect to console redirection)

ipmitool -I lanplus -U root -P calvin -H 192.168.2.62 sol activate

ipmitool -I lanplus -U root -P calvin -H 192.168.2.62 sol deactivate
 
 

No comments: