You could try to start the daemon from command line with debug switch (if available) and watch for an more usefull error message.
It might be enough to link /tmp/var/run to /run or to configure the path within command line or configfile.
i used a following minimalist config just for test:
global_defs {
router_id OWRT-V-01 # give unique id for each router
vrrp_skip_check_adv_addr
}
vrrp_instance VI_1 {
state MASTER # The other router is BACKUP
interface br-mng # the interface where the vrrp is running
virtual_router_id 56
priority 200 # The other router is 100 (the lower is the backup)
advert_int 1
authentication {
auth_type PASS
auth_pass weuigf89
}
virtual_ipaddress {
192.168.56.254 # ip should be changed
}
}
for testing
stop both router
service keepalived stop
first start the backup then the master service keepalived restart; logread -f
The slave first became master then slave when the higher priority router is started :
root@OWRT-V-02:/etc/keepalived# service keepalived restart; logread -f
Tue Aug 18 19:32:42 2020 local1.info Keepalived_vrrp[5475]: Stopped
Tue Aug 18 19:32:42 2020 daemon.info Keepalived[5472]: Stopped Keepalived v2.0.18 (07/26,2019)
Tue Aug 18 19:32:42 2020 daemon.info Keepalived[7411]: Starting Keepalived v2.0.18 (07/26,2019)
Tue Aug 18 19:32:42 2020 daemon.info Keepalived[7411]: WARNING - keepalived was build for newer Linux 4.14.193, running on Linux 4.14.180 #0 SMP Sat May 16 18:32:20 2020
Tue Aug 18 19:32:42 2020 daemon.info Keepalived[7411]: Command line: '/usr/sbin/keepalived' '-n' '-f' '/tmp/keepalived.conf'
Tue Aug 18 19:32:42 2020 daemon.info Keepalived[7411]: Opening file '/tmp/keepalived.conf'.
Tue Aug 18 19:32:42 2020 daemon.info Keepalived[7411]: Starting VRRP child process, pid=7412
Tue Aug 18 19:32:42 2020 local1.info Keepalived_vrrp[7412]: Registering Kernel netlink reflector
Tue Aug 18 19:32:42 2020 local1.info Keepalived_vrrp[7412]: Registering Kernel netlink command channel
Tue Aug 18 19:32:42 2020 local1.info Keepalived_vrrp[7412]: Opening file '/tmp/keepalived.conf'.
Tue Aug 18 19:32:42 2020 local1.info Keepalived_vrrp[7412]: Unable to load magic database
Tue Aug 18 19:32:42 2020 local1.info Keepalived_vrrp[7412]: Registering gratuitous ARP shared channel
Tue Aug 18 19:32:42 2020 local1.info Keepalived_vrrp[7412]: (VI_1) Entering BACKUP STATE (init)
Tue Aug 18 19:32:45 2020 local1.info Keepalived_vrrp[7412]: (VI_1) Entering MASTER STATE
Tue Aug 18 19:33:41 2020 local1.info Keepalived_vrrp[7412]: (VI_1) Master received advert from 192.168.56.2 with higher priority 200, ours 100
Tue Aug 18 19:33:41 2020 local1.info Keepalived_vrrp[7412]: (VI_1) Entering BACKUP STATE
netstat also can be used for checking if VRRP is listening
root@OWRT-V-01:/etc/keepalived# netstat -na| grep -i 112
raw 0 0 0.0.0.0:112 0.0.0.0:* 112
raw 0 0 0.0.0.0:112 0.0.0.0:* 112