巡检脚本 全面

#!/bin/bash # 设置检测环境变量。 source /etc/profile export LC_ALL=C TMP_FILE=/tmp/check_tmp_file CHECK_ID=$(id|sed -e 's/(.*$//' -e 's/^uid=//') if [ $CHECK_ID -ne 0 ] then echo -e "\t你不是root用户!!" exit 0
相关文章
相关标签/搜索