CentOS7 使用ip addr无法显示ip地址

 Centos7 网卡默认是 ens33

1、修改配置

sudo vim /etc/sysconfig/network-scripts/ifcfg-ens33
ONBOOT=no 改成 yes

2、重启网卡服务

/etc/init.d/network restart
原文地址:https://www.cnblogs.com/echola/p/13773596.html