[root@VM-0-17-centos ~]# curl myip.ipip.net | awk '{print $2}'
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 67 100 67 0 0 848 0 --:--:-- --:--:-- --:--:-- 858
IP:1.*.*.*
[root@VM-0-17-centos ~]#
我只想拿到IP地址,但是会打印出耗时这块,不知道为什么,没有想明白,系统是centos7.8.