Linux命令行获取本机*IP地址

问题:

服务器地址为net映射地址,本机ifconfig无法直接获取映射的公网地址。

方法:

[root@TiaoBan-1 nidongde]# curl ip.sb
50.1xx.2xx.18


其他网址访问:

$ curl ip.sb
$ curl cip.cc
$ curl ifconfig.me $ curl icanhazip.com $ curl ident.me $ curl ipecho.net
/plain
原文地址:https://www.cnblogs.com/pzzning/p/9198382.html