![]() |
1
5
您正在中打开一个子shell
在进入while循环之前请尝试:
或者将循环更改为不使用子shell。
|
|
2
0
试着这样做: tail -n 0 -f output.err | grep --line-buffered "Exception" | while read line do echo "An exception has been detected!" | mail -s "ALERT" monitor@company.com kill -term `ps ax | grep tail | grep output.err | awk '{print $1}'` done
|
![]() |
Jerome · 用于检查成功响应的脚本,而不仅仅是200[已关闭] 4 月前 |
![]() |
NullVoxPopuli · 重命名文件夹的最快方法是什么?[关闭] 5 月前 |
![]() |
YorSubs · Linux中遍历目录的时间不同方法[关闭] 6 月前 |
![]() |
Plankt0n · Shell,执行一个需要逐一遍历多个值的命令 6 月前 |
![]() |
Andres Mora · 如何根据文件名条件删除文件夹中的图像? 6 月前 |