随笔分类 -  shell

摘要:一、简单日志清除脚本示例[root@shell scripts]# cat clean_messages.sh #!/bin/bash # 清除日志脚本 LOG_DIR=/var/log ROOT_UID=0 #必须是root用户才能执行 if [ "$UID" -ne "$ROOT_UID" ] then echo "Must be root to run this scr... 阅读全文
posted @ 2020-04-15 14:38 运维人在路上 阅读(179) 评论(0) 推荐(0)