赞
踩
1.命令ip a(自带)
其中ens160 ens224是网卡名字
2.ifconfig 最小化安装没有(需要安装)
yum install -y net-tools.x86_64
这是随机的,可能地址会变化
[root@localhost ~]# dhclient
[root@localhost ~]# nmcli c add type ethernet con-name ens160 ifname ens160 ipv4.addresses 192.168.10.100/24 ipv4.gateway 192.168.10.2 ipv4.dns 8.8.8.8 ipv4.method manual
[root@localhost ~]#
#con-name 连接名
#ifname后加网卡名字
查看连接名
激活连接
[root@localhost ~]# nmcli c up 连接名con-name
网卡配置文件
改了配置文件记得重启网卡配置
[root@localhost ~]# systemctl restart network
依次点击还原默认设置
点更改设置
左下角还原默认设置
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。