36 lines
827 B
Bash
36 lines
827 B
Bash
#!/bin/bash
|
|
|
|
### Introduction of this script
|
|
# Use this script to install test tools
|
|
|
|
# System Requires : centos
|
|
|
|
IPMI_PATH="./ipmitool-1.8.18.rpm"
|
|
FAIL_TASK_CNT=0
|
|
|
|
do_basic_setup(){
|
|
echo ">>> Start do basic setup"
|
|
|
|
# 01. ipmitool
|
|
echo ">>> Start install ipmitool ..."
|
|
if [ -f $IPMI_PATH ];then
|
|
rpm -ivh $IPMI_PATH
|
|
if [ $? -ne 0 ];then
|
|
echo ">>> Fail to install ipmitool , Error In install"
|
|
FAIL_TASK_CNT=$(($FAIL_TASK_CNT+1))
|
|
else
|
|
echo ">>> Success to install ipmitool"
|
|
fi
|
|
else
|
|
echo ">>> Failed to Install ipmitool , Miss the file!"
|
|
FAIL_TASK_CNT=$(($FAIL_TASK_CNT+1))
|
|
fi
|
|
}
|
|
|
|
do_prj_setup(){
|
|
echo ">>> Start do project setup"
|
|
}
|
|
|
|
do_basic_setup
|
|
do_prj_setup
|
|
echo "Complete full install task, Failed : $FAIL_TASK_CNT" |