[command line] curl query public network export IP (reproduced)

Whether it is at home, in the office, or on the company's host, most of the time it is on the intranet, which means that many access the Internet through NAT. Sometimes it is necessary to query the public IP of the export. If you have a browser, you can Use Baidu, google to search  ip this keyword to get the public IP, what if it is under the command line? The following are several interfaces shared by the great gods of the operation and maintenance development group, which are sorted out and shared with you.

liuzhizhi@lzz-rmbp|logs # curl ipinfo.io
{
  "ip": "114.110.1.38",
  "hostname": "No Hostname",
  "city": "Beijing",
  "region": "Beijing Shi",
  "country": "CN",
  "loc": "39.9289,116.3883",
  "org": "AS4808 CNCGROUP IP network China169 Beijing Province Network"
}%

liuzhizhi@lzz-rmbp|logs # curl ip.cn
当前 IP:114.110.1.38 来自:北京市 广东恒敦通信技术北京分公司

liuzhizhi@lzz-rmbp|~ # curl cip.cc
IP  : 114.110.1.38
地址  : 中国  北京市
数据二 : 北京市 | 广东恒敦通信技术北京分公司
URL : http://www.cip.cc/114.110.1.38

liuzhizhi@lzz-rmbp|~ # curl myip.ipip.net
当前 IP:114.110.1.38  来自于:中国 北京 北京 联通/电信

liuzhizhi@lzz-rmbp|~ # curl ifconfig.me
114.110.1.38

liuzhizhi@lzz-rmbp|logs # curl http://members.3322.org/dyndns/getip
114.110.1.38
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28

Several URLs are also very memorable

  • ip.cn
  • ipinfo.io
  • cip.cc
  • ifconfig.me
  • myip.ipip.net

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324848562&siteId=291194637