根据老师的教程记录的sed入门笔记:http://blog.csdn.net/infoflow/article/details/78582968
大家可以参考一下
大家可以参考一下
2017-11-20
一次就够了:
centos7.4:
inet 192.168.33.26 netmask 255.255.255.0 broadcast 192.168.33.255
inet6 fe80::a00:27ff:fea8:5fac prefixlen 64 scopeid 0x20<link>
ifconfig enp0s8|sed 's/^ \+inet \([0-9.]\+\) .*$/\1/'
centos7.4:
inet 192.168.33.26 netmask 255.255.255.0 broadcast 192.168.33.255
inet6 fe80::a00:27ff:fea8:5fac prefixlen 64 scopeid 0x20<link>
ifconfig enp0s8|sed 's/^ \+inet \([0-9.]\+\) .*$/\1/'
2017-11-03