OMSA介绍
Dell OpenManage Server Administrator (OMSA)是一款全面的一对一系统管理解决方案。OMSA可分为两种:
- 集成式界面 - 基于Web浏览器的图形用户界面(GUI)
- 命令行界面(CLI) - 通过操作系统访问
OMSA专为系统管理员设计,可用于管理本地系统及网络中的远程系统.OMSA提供了一个全面的一对一系统管理解决方案包,可使系统管理员专注于整个网络的管理工作。Server Administrator应用程序具有下列特性:
- 简便易用
- 服务器管理
- 存储管理(直连存储 – DAS)
OMSA安装
参考: http://zh.community.dell.com/techcenter/systems-management/w/wiki/561.omsalinux
在有Internet连接的RHEL服务器上安装OMSA
- 运行下面命令来设置Dell OpenManage的yum repository
wget -q -O - http://linux.dell.com/repo/hardware/latest/bootstrap.cgi | bash
- 通过Dell OpenManage的yum repository安装OMSA
# 安装依赖包
yum -y install OpenIPMI
#
yum install srvadmin-all -y
- 安装完成对相关命令做软链接或者设置srvadmin的环境变量
ln -s /opt/dell/srvadmin/sbin/omreport /usr/bin/omreport
ln -s /opt/dell/srvadmin/sbin/omconfig /usr/bin/omconfig
# or
cp /opt/dell/srvadmin/sbin/{omreport,omconfig} /usr/local/bin/
- 启动OMSA
/etc/init.d/dataeng start
- 加入到开机自启动
chkconfig dataeng on
Dell硬件监控工具OMSA常用命令
代码语言:javascript复制#命令可以查看当前系统中安装的软件和硬件组件的综合摘要。
omreport system summary
#CMOS电池状态
omreport chassis batteries
#风扇状态
omreport chassis fans
#内存状态
omreport chassis memory
#网卡状态
omreport chassis nics
#CPU状态
omreport chassis processors
#温度状态
omreport chassis temps
#硬盘状态
omreport storage pdisk controller=0
#电源状态
omreport chassis pwrsupplies
#raid 状态
omreport storage vdisk controller=0
Zabbix服务器上设置
- 创建userparameter_hardware.conf
# 状态1表示正常,状态0表示异常
UserParameter=hardware_battery,omreport chassis batteries | awk '/^Status/{if($NF=="Ok") {print 1} else {print 0}}'
UserParameter=hardware_fan_health,awk -vhardware_fan_number=`omreport chassis fans | grep -c "^Index"` -vhardware_fan=`omreport chassis fans | awk '/^Status/{if($NF=="Ok") count =1}END{print count}'` 'BEGIN{if(hardware_fan_number==hardware_fan) {print 1} else {print 0}}'
UserParameter=hardware_memory_health,awk -vhardware_memory=`omreport chassis memory | awk '/^Health/{print $NF}'` 'BEGIN{if(hardware_memory=="Ok") {print 1} else {print 0}}'
UserParameter=hardware_nic_health,awk -vhardware_nic_number=`omreport chassis nics | grep -c "Interface Name"` -vhardware_nic=`omreport chassis nics | awk '/^Connection Status/{print $NF}'| wc -l` 'BEGIN{if(hardware_nic_number==hardware_nic) {print 1} else {print 0}}'
UserParameter=hardware_cpu,omreport chassis processors|awk '/^Health/{if($NF=="Ok") {print 1} else {print 0}}'
UserParameter=hardware_power_health,awk -vhardware_power_number=`omreport chassis pwrsupplies | grep -c "Index"` -vhardware_power=`omreport chassis pwrsupplies | awk '/^Status/{if($NF=="Ok") count =1}END{print count}'` 'BEGIN{if(hardware_power_number==hardware_power) {print 1} else {print 0}}'
UserParameter=hardware_temp,omreport chassis temps | awk '/^Status/{if($NF=="Ok") {print 1} else {print 0}}' | head -n 1
UserParameter=hardware_physics_health,awk -vhardware_physics_disk_number=`omreport storage pdisk controller=0 | grep -c "^ID"` -vhardware_physics_disk=`omreport storage pdisk controller=0 | awk '/^Status/{if($NF=="Ok") count =1}END{print count}'` 'BEGIN{if(hardware_physics_disk_number==hardware_physics_disk) {print 1} else {print 0}}'
UserParameter=hardware_virtual_health,awk -vhardware_virtual_disk_number=`omreport storage vdisk controller=0 | grep -c "^ID"` -vhardware_virtual_disk=`omreport storage vdisk controller=0 | awk '/^Status/{if($NF=="Ok") count =1}END{print count}'` 'BEGIN{if(hardware_virtual_disk_number==hardware_virtual_disk) {print 1} else {print 0}}'
- 重启zabbix-agent,并检测监控状态
/etc/init.d/zabbix-agent restart
[root@zabbix ~]# zabbix_get -s 127.0.0.1 -p 10050 -k hardware_temp
1
从上面可以看出通过OMSA结合Zabbix对DEll服务器硬件状态进行监控已经完成。
- Zabbix web界面创建相应的Template以及Graph如下:
- 参考链接:
http://zh.community.dell.com/techcenter/systems-management/w/wiki/555.openmanage-server-administrator-omsa http://zh.community.dell.com/techcenter/systems-management/w/wiki/561.omsalinux