Skip to content

Instantly share code, notes, and snippets.

@mtrimarchi
Created April 24, 2017 17:18
Show Gist options
  • Save mtrimarchi/55ce84c9b74582703f219ef5b6994ee3 to your computer and use it in GitHub Desktop.
Save mtrimarchi/55ce84c9b74582703f219ef5b6994ee3 to your computer and use it in GitHub Desktop.
Start keepalived over VLAN at boot

Enable systemd-networkd-wait-online systemctl enable systemd-networkd-wait-online.service

And modify /usr/lib/systemd/system/keepalived.service

[Unit]
Description=LVS and VRRP High Availability Monitor
Wants=network-online.target
After=syslog.target network.target network-online.target
[Service]
Type=forking
PIDFile=/var/run/keepalived.pid
KillMode=process
EnvironmentFile=-/etc/sysconfig/keepalived
ExecStart=/usr/bin/keepalived $KEEPALIVED_OPTIONS
ExecReload=/bin/kill -HUP $MAINPID
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment