[root@m2 keepalived]# service keepalived status
Redirecting to /bin/systemctl status keepalived.service
● keepalived.service - LVS and VRRP High Availability Monitor
Loaded: loaded (/usr/lib/systemd/system/keepalived.service; enabled; vendor preset: disabled)
Active: failed (Result: protocol) since 日 2022-07-24 22:10:26 CST; 7s ago
Process: 22871 ExecStart=/usr/sbin/keepalived $KEEPALIVED_OPTIONS (code=exited, status=0/SUCCESS)
Main PID: 22715 (code=exited, status=0/SUCCESS)
7月 24 22:10:26 m2 systemd[1]: Starting LVS and VRRP High Availability Monitor...
7月 24 22:10:26 m2 Keepalived[22871]: Starting Keepalived v1.3.5 (03/19,2017), git commit v1.3.5-6-g6fa32f2
7月 24 22:10:26 m2 Keepalived[22871]: Configuration file '/etc/keepalived/keepalived.conf' is not a regular non-executable file
7月 24 22:10:26 m2 Keepalived[22871]: Stopped Keepalived v1.3.5 (03/19,2017), git commit v1.3.5-6-g6fa32f2
7月 24 22:10:26 m2 systemd[1]: Can't open PID file /var/run/keepalived.pid (yet?) after start: No such file or directory
7月 24 22:10:26 m2 systemd[1]: Failed to start LVS and VRRP High Availability Monitor.
7月 24 22:10:26 m2 systemd[1]: Unit keepalived.service entered failed state.
7月 24 22:10:26 m2 systemd[1]: keepalived.service failed.
# 解决办法:chmod 644 keepalived.conf
[root@m2 keepalived]# chmod 644 keepalived.conf