shell:iprecord
Differences
This shows you the differences between two versions of the page.
shell:iprecord [2010/03/29 20:47] – created 121.227.64.85 | shell:iprecord [2016/05/05 13:07] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | 用来查询本机外网IP | ||
+ | w3m -dump -no-cookie http:// | ||
+ | <file BASH iprecord.sh> | ||
+ | ######################################################################### | ||
+ | # Author: pengjianqing@sina.com | ||
+ | # Created Time: Mon 10 Aug 2009 09:01:31 PM CST | ||
+ | # File Name: iprecord.sh | ||
+ | # Description: | ||
+ | ######################################################################### | ||
+ | #!/bin/bash | ||
+ | |||
+ | IP=`w3m -dump -no-cookie http:// | ||
+ | OUTPUT=/ | ||
+ | echo " | ||
+ | date >> | ||
+ | echo ${IP} >> | ||
+ | ifconfig|grep inet >> | ||
+ | cat ${OUTPUT} | ||
+ | |||
+ | </ |