标签(空格分隔): Linux


多个关键字 关系

egrep 'CommentManager|getComment' --color catalina.log.2017-03-15
grep -E 'CommentManager|getComment' --color catalina.log.2017-03-15
grep -e 'CommentManager' -e 'getComment' --color catalina.log.2017-03-15
awk '/CommentManager|getComment/' catalina.log.2017-03-15

多个关键字关系

grep  'CommentManager' catalina.log.2017-03-15 | grep 'getComment' --color

grep 所有多个关键字的更多相关文章

  1. grep 满足多个关键字 任意关键字 排除多个关键字

    ① grep -E "word1|word2|word3"   file.txt    满足任意条件(word1.word2和word3之一)将匹配. ② grep word1 f ...

  2. [Linux] shell中for循环grep正则统计指定关键字

    需求是统计某个业务的访问个数日志服务器上的目录结构是如下,搜索最近7天的指定关键字数据,并排重统计个数: drwxr-xr-x root root Nov : -- drwxr-xr-x root r ...

  3. linux命令(10)使用kill杀死含有指定关键字的进程

    命令:ps -ef|grep keyword|grep -v grep|cut -c 9-15|xargs kill -9 批量杀死包含关键字“keyword”的进程. "ps -ef&qu ...

  4. Linux基础正则表达式:grep,sed

    先说明语系对正则表达式的影响    LANG=C:0,1,2,3,4...A,B,C,D...Z a b c d ... z    LANG=zh_CN:0,1,2,3,4...a A b B c C ...

  5. linux三剑客之一grep

    正则表达式(Regular Expression) 目录 起源 正则表达式是什么? 两类基本正则表达式 正则表达式元字符 Linux上文本三剑客 小试牛刀 总结 一.起源   正则表达式这个名词,相信 ...

  6. tail 命令只查看日志中的关键字所在行信息

    tail -f info_log-2019-04-20.log |grep 要查询的关键字

  7. [sh]sh最佳实战(含grep)

    sh虐我千百遍,我待sh如初恋. sh复习资料 http://www.cnblogs.com/iiiiher/p/5385108.html http://blog.csdn.net/iiiiher/a ...

  8. grep 小技巧

    转自:http://www.cnblogs.com/itech/archive/2012/10/18/2729944.html 1) grep命令加- E参数,这一扩展允许使用扩展模式匹配.例如,要抽 ...

  9. linux grep 搜索查找

    查找关键字在哪些文件夹中的哪些文件中出现(只列出文件名称): grep -l 15386257298 */* 查找关键字在哪些文件夹中的哪些文件中出现(列出文件名称+关键字): grep -o 153 ...

随机推荐

  1. POJ 3860 Fruit Weights(数学+最长路径 or 最短路径)

    Description Have you ever thought about comparing the weight of fruits? That’s what you should do in ...

  2. BFS实现模板

    以如下图的无向图G4为例,进行图的深度优先搜索: 假设从顶点v1出发进行搜索,首先访问v1和v1的邻接点v2和v3,然后依次访问v2的邻接点v4和v5及v3的邻接点v6和v7,最后访问v4的邻接点v8 ...

  3. Reactor模式是什么(转载)

    一.Reactor模式是什么反应器设计模式(Reactor pattern)是一种为处理并发服务请求,并将请求提交到一个或者多个服务处理程序的事件设计模式.当客户端请求抵达后,服务处理程序使用多路分配 ...

  4. lintcode-83-落单的数 II

    83-落单的数 II 给出3*n + 1 个的数字,除其中一个数字之外其他每个数字均出现三次,找到这个数字. 样例 给出 [1,1,2,3,3,3,2,2,4,1] ,返回 4 挑战 一次遍历,常数级 ...

  5. java第七笔记

  6. PhoneGap & HTML5 学习资料网址

    PhoneGap 与 Application Cache应用缓存  http://www.html5cn.org/forum.php?mod=viewthread&tid=40272 加速We ...

  7. [bzoj4832][Lydsy1704月赛]抵制克苏恩

    题目大意:有一个英雄和若干个所从,克苏恩会攻击$K$次,每次回随机攻击对方的一个人,造成$1$的伤害.现在对方有一名克苏恩,你有一些随从.如果克苏恩攻击了你的一名随从,若这名随从不死且你的随从数量不到 ...

  8. error C3872: '0x3000': this character is not allowed in an identifier 解决方法

    文章参考地址:http://blog.csdn.net/danxuezx/article/details/5096497 编译时遇到这个错误多半是从网上拷贝一段代码到VS里然后编译时产生的,这是因为拷 ...

  9. [Leetcode] Multiply strings 字符串对应数字相乘

    Given two numbers represented as strings, return multiplication of the numbers as a string. Note: Th ...

  10. C语言一些常用的功能

    1.测试运行时间: #include<stdio.h> #include<stdlib.h> #include<time.h> int main() { clock ...