IPMI常用指标

查看指标

ipmitool sdr elist

获取指标值

ipmitool get "传感器名称"

传感器名称 说明
Ambient Temp 主机温度
FAN 风扇转速
CPU CPU状态
DIMM 内存状态
DISK 磁盘状态
PSU 电源状态

IPMITOOL命令参考

查看cpu信息

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr elist | grep 'Status'

查看内存信息

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr elist | grep 'DIMM'

查看电源

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr get "Pwr"

查看风扇

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr get "Fan"

查看温度

#服务器进风口温度
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr get "Inlet"
#服务器出风口温度
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr get "Exhaust Temp"
#CPU当前温度
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr get "Temp"

查看网络MAC地址

ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan print |grep "MAC Address"

查看时间,收集管理卡当前时钟信息,以“年月日时分秒”格式显示

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sel time get

查看事件,异常事件、操作事件、登录事件记录

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sel list

查看服务器的网络配置信息

ipmitool -I lan -H $HOST -U $USER -P $PASS lan print

查看服务器的温度信息

ipmitool -I lan -H $HOST -U $USER -P $PASS sdr get "Ambient Temp"

查看服务器的功率信息

ipmitool -I lan -H $HOST -U $USER -P $PASS sdr get "System Level"

查看服务器的序列号信息

ipmitool -I lan -H $HOST -U $USER -P $PASS fru

查看服务器的MAC

ipmitool -I lan -H $HOST -U $USER -P $PASSWD delloem mac

查看服务器的资产号信息

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sdr get "System Level"

查看服务器的管理卡的时间

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sel time get

查看管理卡配置模式

ipmitool -I lan -H $HOST -U $USER -P $PASSWD delloem lan get

查看SOL波特率

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol info 1

服务器开机、关机、重启

ipmitool -I lan -H $HOST -U $USER -P $PASSWD power
ipmitool -I lan -H $HOST -U $USER -P $PASSWD power status

服务器添加用户、设置密码、授予权限

ipmitool -I lan -H $HOST -U $USER -P $PASSWD user list 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD user set name 10 test1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD user set password 10 test1pwd
ipmitool -I lan -H $HOST -U $USER -P $PASSWD user enable 10
ipmitool -I lan -H $HOST -U $USER -P $PASSWD user list 1
# 1-CALLBACK ,2-USER ,3-OPERATOR ,4-ADMNISTRATOR
ipmitool -I lan -H $HOST -U $USER -P $PASSWD user priv 10 4 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD user list 1

管理卡IP配置模式转换(DHCP/静态IP)

ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan set 1 ipsrc 
ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan set 1 ipsrc static
ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan print

管理卡修改IP地址

read -p "modify oob ip, please use the current network : " oobip
read -p "modify oob netmask : " netmask
read -p "modify oob gateway : " oobgw
ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan set 1 ipaddr $oobip
ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan set 1 netmask $netmask
ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan set 1 defgw ipaddr $oobgw
ipmitool -I lan -H $HOST -U $USER -P $PASSWD lan print

管理卡配置模式转换(独立/共享) 仅dell

#独立
ipmitool -I lan -H $HOST -U $USER -P $PASSWD delloem lan
#共享
ipmitool -I lan -H $HOST -U $USER -P $PASSWD delloem lan set dedicated

设置SOL波特率

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol set non-volatile-bit-rate 115.2 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol info 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol set non-volatile-bit-rate 57.6 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol info 1

SOL模式开启、关闭

ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol set enabled true 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol info 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol set enabled false 1
ipmitool -I lan -H $HOST -U $USER -P $PASSWD sol info 1

results matching ""

    No results matching ""