以下為 linux 如何獲取公網 ip 的方法
curl cip.cc
- linux 命令:
curl cip.cc
- windows 命令:
telnet cip.cc
- 純 IP 命令:
curl ip.cip.cc
[root@localhost ~]# curl cip.cc
IP : 115.196.88.33
地址 : 中國 北京
運營商 : 阿里雲/聯通/電信/移動
數據二 : 北京市 | 阿里雲
數據三 : 中國北京北京 | 電信
URL : http://www.cip.cc/115.196.88.33
[root@localhost ~]# curl ip.cip.cc
116.196.112.113
curl ifconfig.me
[root@localhost ~]# curl ifconfig.me
116.196.112.113