检查软件包是否安装,如果未安装则执行安装 __init_yum() { _is_install=$(yum list installed ipmitool | grep -Ec 'lipmitoolsof') if ((_is_install != 1)); then yum -y install ipmitool fi}