/*在当前目录下查找*/
eric@mars-64:~/servers$ pwd
/home/eric/servers
eric@mars-64:~/servers$ grep -irl "maven3.0.4" ./
./tomcat7.0.29/logs/localhost_access_log.2012-07-22.txt
./tomcat7.0.29/logs/localhost_access_log.2012-07-21.txt
/*shell获取ip地址*/
ifconfig | grep 'inet addr:' | grep -v '127.0.0.1' | cut -d: -f2 | awk '{print $1}'
/*查看端口情况*/
netstat -ntlp
参考:
http://blog.csdn.net/wj_j2ee/article/details/6934371