egrep ‘bash$‘ /etc/passwd
egrep ‘\<[[:digit:]]{2,3}\>‘ /etc/passwd
netstat -tan
命令结果中以’LISTEN’后跟0个、1个或者多个空白字符结尾的行netstat -nat | egrep ‘\<LISTEN[[:blank:]]*‘
egrep ‘^([[:alnum:]]*\>).*\1$‘ /etc/passwd
egrep ‘^(centos|user1|root)‘ /etc/passwd | cut -d: -f3,7
egrep ‘([[:alpha:]]|_)+\(\)‘ /etc/rc.d/init.d/functions
egrep ... //TODO
ifconfig | egrep ‘\<(1?[1-9]{1,2}|2[0-5]{2})\>‘
本文出自 “Robot” 博客,请务必保留此出处http://molloc.blog.51cto.com/1143037/1689701
原文地址:http://molloc.blog.51cto.com/1143037/1689701