环境:在macos-vmware-linux(centOS7)
yum 不能正常使用
Could not resolve host:mirrorlist.centos.org; Unknown error.网上查了下原因:“本机无法连接网络的网络设置”。
步骤一:[root@localhost ~]# nmcli d

步骤二:[root@localhost ~]# nmtui(打开网络管理员)
1:选择“Edit a connection”后按回车键(使用TAB键进行选择的选项)
2:现在可以看到所有的网络接口,选择一个(我的是ens160),然后键盘上下左右键选择到“Edit”并Enter确认进入:
步骤4:进行动态配置:
(1)在IPv4 CONFIGURATION配置选择<Automatic>;
(2)按空格键选择“Automatically connetc”复选框;
(3)点击OK键,退出网络管理器;
(4)依次Back Exit,返回终端界面;
(5)输入命令重新启动网络服务:[root@localhost ~]# systemctl restart network



网友评论