Reinstalled a few virtual machines today, and it's like this after cloning
[root@llq-control ~]# systemctl start network
Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details.
[root@llq-control ~]# systemctl status network
● network.service - LSB: Bring up/down networking
Loaded: loaded (/etc/rc.d/init.d/network; bad; vendor preset: disabled)
Active: failed (Result: exit-code) since 日 2022-09-19 22:44:34 CST; 1s ago
Docs: man:systemd-sysv-generator(8)
Process: 5042 ExecStart=/etc/rc.d/init.d/network start (code=exited, status=1/FAILURE)
9月 29 22:44:34 llq-control network[5042]: RTNETLINK answers: File exists
9月 29 22:44:34 llq-control network[5042]: RTNETLINK answers: File exists
9月 29 22:44:34 llq-control network[5042]: RTNETLINK answers: File exists
9月 29 22:44:34 llq-control network[5042]: RTNETLINK answers: File exists
9月 29 22:44:34 llq-control network[5042]: RTNETLINK answers: File exists
9月 29 22:44:34 llq-control network[5042]: RTNETLINK answers: File exists
9月 29 22:44:34 llq-control systemd[1]: network.service: control process exited, code=exited...s=1
9月 29 22:44:34 llq-control systemd[1]: Failed to start LSB: Bring up/down networking.
9月 29 22:44:34 llq-control systemd[1]: Unit network.service entered failed state.
9月 29 22:44:34 llq-control systemd[1]: network.service failed.
Hint: Some lines were ellipsized, use -l to show in full.
Solution
1. Close NetworkManager, and set the service to not start by default:
[root@llq-control ~]# systemctl stop NetworkManager
[root@llq-control ~]# systemctl disable NetworkManager
Removed symlink /etc/systemd/system/multi-user.target.wants/NetworkManager.service.
Removed symlink /etc/systemd/system/dbus-org.freedesktop.NetworkManager.service.
Removed symlink /etc/systemd/system/dbus-org.freedesktop.nm-dispatcher.service.
2. Restart the network service
[root@llq-control ~]# systemctl status network.service
● network.service - LSB: Bring up/down networking
Loaded: loaded (/etc/rc.d/init.d/network; bad; vendor preset: disabled)
Active: failed (Result: exit-code) since 日 2022-09-19 22:53:32 CST; 9s ago
Docs: man:systemd-sysv-generator(8)
Process: 3620 ExecStart=/etc/rc.d/init.d/network start (code=exited, status=1/FAILURE)
If it is found that the error is still reported, it is a problem with the MAC address.
3. Query the hardware address of the host:
ip addr show
4. Modify the /etc/sysconfig/network-scripts/ifcfg-config_1 file
Step 6: Restart the network again
[root@llq-control ~]# systemctl restart network
[root@llq-control ~]# systemctl status network