Home  >  Article  >  Operation and Maintenance  >  What should I do if the centos system fails to restart the network?

What should I do if the centos system fails to restart the network?

王林
王林Original
2020-03-23 10:56:126017browse

What should I do if the centos system fails to restart the network?

Environment: centos7 system

Problem description:

[root@localhost Desktop]# systemctl start network.service
Job for network.service failed. See 'systemctl status network.service' and 'journalctl -xn' for details.

Solution:

1. HWADDR error, find the correct one HWADDR

Enter ip addr, find HWADDR

What should I do if the centos system fails to restart the network?

and enter cd /etc/sysconfig/network-scripts Edit the corresponding vim ifcfg-ensXX, set the HWADDR correctly, and restart

service network restart

If it still doesn’t work, you need to reset the IP.

(Recommended tutorial: centos usage tutorial)

2. IP check and setting

Enter the host cmd command window and enter ipconfig / all

What should I do if the centos system fails to restart the network?

Then enter the centos7 virtual machine cd /etc/sysconfig/network-scripts Edit the corresponding vim ifcfg-ensXX

What should I do if the centos system fails to restart the network?

Then turn off the network:

root@localhost Desktop]# service NetworkManager stop
Redirecting to /bin/systemctl stop  NetworkManager.service

Then restart:

[root@localhost Desktop]# service network restart
Restarting network (via systemctl):                        [  OK  ]

Recommended related video tutorials: linux video tutorial

The above is the detailed content of What should I do if the centos system fails to restart the network?. 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