Linux sed正则匹配删除整行

原文内容:
[root@10 tmp]# more test.log
2019-12-01 09:09:02 Failed
2019-12-01 09:12:02 Failed
2019-12-01 09:15:03 Failed
2019-12-01 09:18:02 Failed

正则匹配Failed,删除整行(直接替换文本内容)
[root@107 tmp] sed -i '/Failed$/'d check.log

posted @ 2019-12-01 09:43  小 伍  阅读(4246)  评论(0编辑  收藏  举报