Skip to content

Commit

Permalink
vip-manager.service: add "After=network-online.target"
Browse files Browse the repository at this point in the history
network-online.target is a target that actively waits until the nework is "up".

fixed:
Sep 15 14:07:57 cas-pgnode02 systemd[1]: Started Manages Virtual IP for Patroni.
Sep 15 14:07:57 cas-pgnode02 vip-manager[595]: 2020/09/15 14:07:57 reading config from /etc/patroni/vip-manager.yml
Sep 15 14:07:57 cas-pgnode02 vip-manager[595]: 2020/09/15 14:07:57 Obtaining the interface raised an error: route ip+net: no such network interface
Sep 15 14:07:57 cas-pgnode02 systemd[1]: vip-manager.service: Main process exited, code=exited, status=1/FAILURE
Sep 15 14:07:57 cas-pgnode02 ip[607]: Cannot find device "vlan150"
Sep 15 14:07:57 cas-pgnode02 systemd[1]: vip-manager.service: Control process exited, code=exited, status=1/FAILURE
Sep 15 14:07:57 cas-pgnode02 systemd[1]: vip-manager.service: Failed with result 'exit-code'.
  • Loading branch information
vitabaks committed Sep 15, 2020
1 parent 454c7aa commit 6cee7e5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions roles/vip-manager/templates/vip-manager.service.j2
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
[Unit]
Description=Manages Virtual IP for Patroni
After=network-online.target
Before=patroni.service

[Service]
Expand Down

0 comments on commit 6cee7e5

Please sign in to comment.