2019年5月17日

clearLog_New_v2.sh

摘要: #!/bin/sh #@author lixiaoguang1 function deleteLog(){ local path pathList #path 为输入的路径 path=$1 #pathList为按照log条件检索的结果 pathList=$(find ${path} -name "*.log" ... 阅读全文

posted @ 2019-05-17 17:29 东京的花 阅读(123) 评论(0) 推荐(0)

clearLog 新版本

摘要: function deleteLog(){ local path pathList #path 为输入的路径 path=$1 #pathList为查找后的路径list pathList=$(find ${path} -name "*.log" -o -name "*.out" -o -name "*.log.*") ... 阅读全文

posted @ 2019-05-17 11:46 东京的花 阅读(192) 评论(0) 推荐(0)

remoteClearLog

摘要: clearLog(){ sshpass -p $3 scp /export/servers/clearLog_New.sh $1@$2:/export/servers sshpass -p $3 ssh $1@$2 "sh /export/servers/clearLog_New.sh $4" } clearLog $1 $2 $3 $4 阅读全文

posted @ 2019-05-17 11:44 东京的花 阅读(97) 评论(0) 推荐(0)

clearLog 旧版本

摘要: function scandir() { local cur_dir parent_dir workdir workdir=$1 cd ${workdir} if [ ${workdir} = "/" ] then cur_dir="" else cur_dir=$(pwd) fi for di... 阅读全文

posted @ 2019-05-17 11:44 东京的花 阅读(174) 评论(0) 推荐(0)

导航