Home >Operation and Maintenance >CentOS >What should I do if the centos system does not recognize the network card?

What should I do if the centos system does not recognize the network card?

王林
王林Original
2020-03-30 15:51:155586browse

What should I do if the centos system does not recognize the network card?

Problem:

The network card cannot be recognized after adding it to CentOS in the virtual machine.

Solution:

1. Get the real mac of the new network card

#ip addr

What should I do if the centos system does not recognize the network card?

(Recommended tutorial: centos tutorial)

2. Copy eth0 to eth1 and modify the configuration file

#cd /etc/sysconfig/network-scripts
#cp ifcfg-eth0 ifcfg-eth1
#vim ifcfg-eth1

The contents to be modified are:

HWADD    #通过ip addr获取
UUI     #若没有查到UUID,可以注释掉
NAME     #改为当前的网卡名eth1
DEVICE   #改为当前的网卡名eth1
IPADDR
GATEWAY

Save and exit.

3. Restart the network card

#systemctl restart network

Recommended related video tutorials: linux video tutorial

The above is the detailed content of What should I do if the centos system does not recognize the network card?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn