Solve the problem that the network cannot be connected after the centos 7 VM is restarted

Source: Internet
Author: User

Solve the problem that the network cannot be connected after the centos 7 VM is restarted

Centos7 introduces a new network device naming method-consistent network device naming (consistent network device naming) due to systemd and udev ).

One virtual machine, centos 7 64-bit system installed, dual Nic, Intranet is ens33, internet is ens32. After the system is restarted, the network is disconnected. Check that the network is not started on the console. manually start the Intranet. You can ping the network card and start the Internet Nic. Check IP Address

Ip

It is found that the Intranet address is bound to the public network card.

Cd/etc/sysconfig/network-scripts/
Cat ifcfg-ens32 | grep HWADDR
Ip l | grep-A 1 ens32

Modify Nic configuration and add mac address parameters

HWADDR =...

Restart Nic

Ifdown ens32 & ifup ens32

The network can be connected normally.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.