一般命令
raw                #发送一个原始的IPMI请求,并且打印回复信息。
Lan                #配置网络(lan)信道(channel)
chassis            #查看底盘的状态和设置电源
event              #向BMC发送一个已经定义的事件(event),可用于测试配置的SNMP是否成功
mc                 #查看MC(Management Contollor)状态和各种允许的项
sdr                #打印传感器仓库中的所有监控项和从传感器读取到的值。
Sensor             #打印详细的传感器信息。
Fru                #打印内建的Field Replaceable Unit (FRU)信息
Sel                #打印 System Event Log (SEL)
Pef                #设置 Platform Event Filtering (PEF),事件过滤平台用于在监控系统发现有event时候,用PEF中的策略进行事件过滤,然后看是否需要报警。
Sol/isol           #用于配置通过串口的Lan进行监控
User               #设置BMC中用户的信息 。
Channel            #设置Management Controller信道。
Ipmitool –I open sensor list              #命令可以获取传感器中的各种监测值和该值的监测阈值,包括(CPU温度,电压,风扇转速,电源调制模块温度,电源电压等信息)
Ipmitool –I open sensor get “CPU0Temp”  #可以获取ID为CPU0Temp监测值,CPU0Temp是sensor的ID,服务器不同,ID表示也不同。
Ipmitool –I open sensor thresh          #设置ID值等于id的监测项的各种限制值。
Ipmitool –I open chassis status         #查看底盘状态,其中包括了底盘电源信息,底盘工作状态等
Ipmitool –I open chassis restart_cause  #查看上次系统重启的原因
Ipmitool –I open chassis policy list    #查看支持的底盘电源相关策略。
Ipmitool –I open chassis power on       #启动底盘,用此命令可以远程开机
Ipmitool –I open chassis power off      #关闭底盘,用此命令可以远程关机
Ipmitool –I open chassis power reset    #实现硬重启,用此命令可以远程重启
#Ipmi还可以设置系统启动boot的设备,具体见ipmitool帮助文档
Ipmitool –I open mc reset                #使BMC重新硬启动
Ipmitool –I open mc info                 #查看BMC硬件信息
Ipmitool –I open mc getenables           #列出BMC所有允许的选项
Ipmitool –I open mc setenables =[on|off] #设置bmc相应的允许/禁止选项。
Ipmitool-I open event                   #发送一个温度过高的消息到System Event Log中,可以发送的Event有:
Temperature: Upper Critical: Going High
Voltage Threshold: Lower Critical: Going Low
Memory: Correctable ECC Error Detected
Ipmitool-I open event                          #命令可以用测试配置的IPMI中的snmp功能是否成功。
Ipmitool -I open lan print                    #打印现咱channel 1的信息 。
Ipmitool -I open lan set  ipaddr
Ipmitool -I open lan set  snmp public         #设置channel  上snmp的community为public。
Ipmitool -I open lan set  access on           #设置channel 1允许访问。
Ipmitool -I open pef info                      #打印Platform Event Filtering (pef)信息
Ipmitool -I open pef status                    #查看Platform Event Filtering (pef)状态
Ipmitool -I open pef policy                    #查看Platform Event Filtering (pef)策略设置
Ipmitool -I open sdr list fru                  #读取fru信息并显示。
ipmitool sel clear                             #清除记录
ipmitool sel elist
ipmitool sel list
ipmitool fru
ipmitool fru print                             #显示fru信息
ipmitool fru print
ipmitool fru print
ipmitool bmc reset cold                        #重启bmc
ipmitool sdr                                   #查看psu fan (BAT)等信息
ipmitool sdr type fan
ipmitool mc info                               #查看bmc信息
ipmitool lan print                             #显示lan信息
ipmitool lan print|egrep "MAC Address"         #得到bmc的oui
ipmitool lan set  ipsrc dhcp                  #设置动态ip 1用户
ipmitool -H $bmc_ip -U admin -P admin mc info  #设置用户名密码
ipmitool chassis policy always-off
ipmitool chassis identify force
ipmitool chassis identify off
ipmitool sdr type Temperature
ipmitool sol payload enable
IPMI RAW command
参照IPMI spec 2.0 with KCS
BMC 可以控制的功能很多, 除了常用的ipmi command, 其馀还有许多,可以依靠RAW command 来与BMC 沟通完成, 并且有"隐藏"的command 可以用,尤其是OEM command, 可以询问各机种BMC RD
以下整理出来较有用的command, 需注意Data 的Request/Response 起始位置。
Request 指令格式 "ipmitool raw NetFnCode CommandCode Data .."
Ex.ipmitool raw 0x0C 0x02 0x01 0x04 0x00 0x00(Get BMC IP Source)
0x0C Request Transport Media-specific configuration & control
0x02 GET LAN Config
0x01 Channel Num
0x04 IP Source(Selector)
0x00 not use set Selector
0x00 not require block num
Response 指令格式 "NetFnCode CommandCode CopmpletionCode Data .."
Ex.0x0D 0x02 0x00 0x01
0x0D Response Transport Media-specific configuration & control
0x02 GET LAN Config
0x00 Command Completed Successful
0x01 IP source is Static
## NetFn code
0x00(request), 0x01(Response) Chassis
0x02(request), 0x03(Response) Bridge
0x04(request), 0x05(Response) Sensor/Event
0x06(request), 0x07(Response) Application
0x08(request), 0x09(Response) Firmware Transfer
0x0A(request), 0x0B(Response) Non-volatile storage
0x0C(request), 0x0D(Response) Transport Media-specific configuration & control
0x0E- 0x2B Reserved
2Ch-2Dh Extension Non-IPMI group
2Eh-2Fh OEM/Non-IPMI group
30h-3Fh Controllerspecific OEM/Group
## Completion Code
0x00 Command Completed Normally
0xC0 Node Busy
0xC1 Invalid Command
0xC2 Command invalid for given NetFn
0xC3 Timeout
0xC4 Storage Out of space
0xC5 Reservation Canceled or Invalid Reservation ID
0xC6 Request data truncated
0xC7 Request data length invalid
0xC8 Request data field length limit exceeded
0xC9 Parameter/Data out of range
0xCA Cannot return number of requested data bytes
0xCB Requested Sensor, data, or record not present
0xCC Invalid data field in Request
0xCD Command illegal for specified sensor or record type
0xCE Command response could not be provided
0xCF Cannot execute duplicated request
0xD0 Command response could not be provided. SDR Repository in update mode.
0xD1 Command response could not be provided. Device in firmware update mode.
0xD2 Command response could not be provided. BMC initialization or
initializationagent in progress
0xD3 Destination unavailable
0xD4 Cannot execute command due to insufficient privilege level or other
securitybased restriction
0xD5 Cannot execute command. Command or parameter not supported in present
state
0xD6 Cannot execute command. Parameter is illegal
0xFF Unspecified error
0x01-0x7E OEM completion codes
0x80-0xBE Standard command-specific codes
0x7F, 0xBF, 0xD7-0xFE Reserved

服务器之ipmitool的更多相关文章

  1. Web服务器之iis,apache,tomcat三者之间的比较

    IIS-Apache-Tomcat的区别 IIS与Tomcat的区别 IIS是微软公司的Web服务器.主要支持ASP语言环境. Tomcat是Java Servlet 2.2和JavaServer P ...

  2. linux服务器之LVS、Nginx和HAProxy负载均衡器对比

    linux服务器之LVS.Nginx和HAProxy负载均衡器对比. LVS特点:  1.抗负载能力强,使用IP负载均衡技术,只做分发,所以LVS本身并没有多少流量产生:  2.稳定性.可靠性好,自身 ...

  3. 【转】Android 服务器之SFTP服务器上传下载功能

    原文网址:http://blog.csdn.net/tanghua0809/article/details/47056327 本文主要是讲解Android服务器之SFTP服务器的上传下载功能,也是对之 ...

  4. 搭建VPN服务器之PPTP

    搭建VPN服务器之PPTP 1. 查看系统是否支持PPP 一般自己的系统支持,VPS需要验证. [root@oldboyedu ~]# cat /dev/ppp cat: /dev/ppp: No s ...

  5. linux下维护服务器之常用命令

    linux下维护服务器之常用命令! 第1套如下: 正则表达式: 1.如何不要文件中的空白行和注释语句: [root@localhost ~]# grep -v '^$' 文件名 |grep -v '^ ...

  6. backup服务器之rsync服务

    backup服务器之rsync服务   rsync是开源的.快速的.多功能的可实现全量及增量的本地或远程数据同步备份的优秀工具.它拥有scp.cp的全量复制功能,同时比scp.cp命令更优秀.更强大. ...

  7. 【转】Android 服务器之SFTP服务器上传下载功能 -- 不错

    原文网址:http://blog.csdn.net/tanghua0809/article/details/47056327 本文主要是讲解Android服务器之SFTP服务器的上传下载功能,也是对之 ...

  8. Session服务器之Memcached与Redis

    安装Memcached[root@nginx ~]# yum -y install libevent memcached 指定用户大小等信息,工作环境中常指定大小一般为4到8G,此信息测试使用.[ro ...

  9. Session服务器之Redis

    Session服务器之Redis Redis与Memcached的区别内存利用率:使用简单的key value (键值对)存储的话,Mermcached 的内存利用率更高,而如果Redis采用hash ...

随机推荐

  1. RequireJS全面讲解

    异步模块定义(AMD)  谈起RequireJS,你无法绕过提及JavaScript模块是什么,以及AMD是什么. JavaScript模块只是遵循SRP(Single Responsibility  ...

  2. [TypeScript] Create Explicit and Readable Type Declarations with TypeScript mapped Type Modifiers

    Using the optional “+” sign together with mapped type modifiers, we can create more explicit and rea ...

  3. ArcGIS教程:Iso 聚类非监督分类

    摘要 使用 Iso 聚类工具和最大似然法分类工具对一系列输入栅格波段运行非监督分类. 使用方法 · 此工具结合了 Iso 聚类工具与最大似然法分类工具的功能.输出经过分类的栅格.作为可选的,它也能够输 ...

  4. JavaScript对象深复制

    1.原理 使用JSON,当然需要JSON安全的格式,JSON安全请参考:http://www.cnblogs.com/mengfangui/p/8257269.html 2.示例 <!DOCTY ...

  5. CentOS 7上安装Zabbix(高速安装监控工具Zabbix)

    前提要求(optional) 安装Zabbix监控工具前,先安装必要的执行工具包 yum install gcc gcc-c++ make openssl-devel curl wget net-sn ...

  6. JAVA的IO编程:管道流

    掌握线程通讯流(管道流)的使用 管道流的主要作用是可以进行两个线程间的通讯,分为管道输入流(PipeOutputStream)和管道输出流(PipeInputStream). 如果要想进行管道输出,则 ...

  7. iOS 转盘动画效果实现

    代码地址如下:http://www.demodashi.com/demo/11598.html 近期公司项目告一段落,闲来无事,看到山东中国移动客户端有个转盘动画挺酷的.于是试着实现一下,看似简单,可 ...

  8. HttpClient POST 的 UTF-8 编码问题

    http://www.360doc.com/content/09/0915/15/61497_6003890.shtml不 过在实际使用中, 还是发现按照最基本的方式调用 HttpClient 时, ...

  9. Azure Storage 分块上传

    概述 Azure 存储提供三种类型的 Blob:块 Blob.页 Blob 和追加 Blob.其中,块 Blob 特别适用于存储短的文本或二进制文件,例如文档和媒体文件. 块 Blob 由块组成,每个 ...

  10. datagridview 日期列排序

    1.datagridview 日期列排序 private void Form1_Load(object sender, EventArgs e) { //方法1 dataGridView1.Colum ...