本文主要是介绍vmware 虚拟机中添加新网卡无配置文件,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
问题:
为虚拟机添加新网卡后,/etc/sysconfig/network-scripts/下无配置文件ifcfg-eth1
#ip addr //显示存在eth1
#ip addr eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000link/ether 00:0c:29:17:29:66 brd ff:ff:ff:ff:ff:ffinet 192.168.192.135/24 brd 192.168.192.255 scope global dynamic eth1valid_lft 1482sec preferred_lft 1482secinet6 fe80::20c:29ff:fe17:2966/64 scope link valid_lft forever preferred_lft forever
解决:
#cp /etc/sysconfig/network-scripts/ifcfg-eth0 /etc/sysconfig/network-scripts/ifcfg-eth1 #vim /etc/sysconfig/network-scripts/ifcfg-eth1 HWADDR=00:0C:29:17:29:66 #修改为eth1的mac地址 TYPE=Ethernet BOOTPROTO=static DEFROUTE=no PEERDNS=yes PEERROUTES=yes IPV4_FAILURE_FATAL=no IPV6INIT=yes IPV6_AUTOCONF=yes IPV6_DEFROUTE=yes IPV6_PEERDNS=yes IPV6_PEERROUTES=yes IPV6_FAILURE_FATAL=no NAME=eth1 #修改为eth1 #UUID=93285a79-5ad6-4d55-ae5a-b417ce7f4d31 #注释掉 ONBOOT=yes #service network restart
这篇关于vmware 虚拟机中添加新网卡无配置文件的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!