1,021   Linux

1,在命令运行后输出内容里查找

# sysctl -a |  grep -s ‘overcommit_memory’

sysctl -a : 输出内核参数

-s : 不输出错误信息

 

2,搜索指定文件中内容

# find . -name “*.properties” | xargs grep -n ‘jdbc’

 

-name “*.properties” : 指定文件后缀

xargs : 输出文件内容

-n : 显示行数

 

 




Leave a Reply

Your email address will not be published. Required fields are marked *