“Job for network.service failed because the control process exite”问题
[root@node3 ~]# service network restart Restarting network (via systemctl): Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details. 怎么解决?
要解决这个问题,你需要查看 "systemctl status network.service" 和 "journalctl -xe" 命令的输出,这将提供有关错误的更多信息。首先运行以下命令来查看网络服务的状态:
systemctl status network.service
然后,运行以下命令来查看系统日志以获取更多的上下文信息:
journalctl -xe
这些命令将显示出导致网络服务无法重启的具体错误。根据这些错误信息,你可以采取相应的措施来解决问题。
然后就会这样
[root@node3 ~]# 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 Wed 2023-11-08 22:56:59 CST; 9h ago Docs: man:systemd-sysv-generator(8) Process: 3856 ExecStart=/etc/rc.d/init.d/network start (code=exited, status=1/FAILURE)
Nov 08 22:56:59 node3 network[3856]: RTNETLINK answers: File exists Nov 08 22:56:59 node3 network[3856]: RTNETLINK answers: File exists Nov 08 22:56:59 node3 network[3856]: RTNETLINK answers: File exists Nov 08 22:56:59 node3 network[3856]: RTNETLINK answers: File exists Nov 08 22:56:59 node3 network[3856]: RTNETLINK answers: File exists Nov 08 22:56:59 node3 network[3856]: RTNETLINK answers: File exists Nov 08 22:56:59 node3 systemd[1]: network.service: control process exited, ...=1 Nov 08 22:56:59 node3 systemd[1]: Failed to start LSB: Bring up/down networking. Nov 08 22:56:59 node3 systemd[1]: Unit network.service entered failed state. Nov 08 22:56:59 node3 systemd[1]: network.service failed. Hint: Some lines were ellipsized, use -l to show in full.
我们需要
NetworkManager 服务有冲突,直接关闭 NetworkManger 服务就好了,
service NetworkManager stop
禁止开机启动
chkconfig NetworkManager off
重启网络
service network restart