首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 其他教程 > 互联网 >

linux 上获取 互联网ip

2012-08-24 
linux 下获取 互联网ip方式一:?[root@centos200 monitor_adsl_connect]# ifconfig?方式二:?[oracle@localh

linux 下获取 互联网ip

方式一:

?[root@centos200 monitor_adsl_connect]# ifconfig

?

方式二:

?

[oracle@localhost ~]$ curl http://www.ip138.com/ip2city.asp | grep body | awk -F "[" '{print $2}'| awk -F "]' '{print $1}'
114.249.210.26

?方式三:

?

[wusx@centos245 CycleTaskManager]$ curl -s 'http://checkip.dyndns.org' | sed 's/.*Current IP Address: \([0-9\.]*\).*/\1/g'
114.249.221.61

热点排行