Tag Archives: Unit network.service not found

Failed to restart network.service: Unit network.service not found

This problem occurs when you restart after configuring the network settings. The reason for this problem is due to the connection with the network manager   The solution is to shut down NetworkManager and restart the network service

service NetworkManager stop //关闭NetworkManager
service network restart //启动network服务 (vm 下安装 centos 可用 nmcli c reload 命令启动)

The difference between network and NetworkManager
Network: after the configuration information of network card and network control network interface is changed, the network service must be restarted to activate the new configuration of the network and make the configuration effective. This part of the operation is the same as starting the system again. Control (control) is the file/etc/init.d/network. You can use this file with the following parameters to operate network services

Network manager: it is a program to detect the network and automatically connect to the network. Whether it’s wireless or wired, it’s easy to manage. For wireless network, network manager can automatically switch to the most reliable wireless network. The program of network manager can switch between online mode and offline mode freely. Network manager can give priority to wired network and support VPN. The network manager was originally developed by RedHat and is now managed by gnome

Some commands about network manager are arranged as follows:

service NetworkManager stop //close NetworkManager
service NetworkManager status //check NetworkManager status
chkconfig NetworkManager off //Disable boot-up
chkconfig NetworkManager on //boot-up
service NetworkManager start //Temporarily start
chkconfig NetworkManager off // Permanently disable the NetworkManager hosting tool