Page MenuHomeVyOS Platform

After removal load-balancing a pid remained which used in dhclient-exit-hooks
Closed, ResolvedPublicBUG

Description

After adding and removing load-balancing configuration there's a PID that exists after the config removing.
This pid used in dhcp-exit-hook

So if we don't have load-balancing in the configuration it tries to send the user signal to not exist process kill -s SIGUSR2 xxx

To reproduce:

set load-balancing wan interface-health eth1 nexthop dhcp
commit
delete load-balancing
commit
run renew dhcp interface ethX

File exists after removing load-balancing

vyos@vyos2# file /var/run/vyatta/wlb.pid
/var/run/vyatta/wlb.pid: ASCII text

Log:

May 04 12:55:14 vyos2 root[8725]: /etc/dhcp/dhclient-exit-hooks.d/04-dhcp-wanlb returned non-zero exit status 1

Propose to use OR in the hook or remove the PID properly

kill -s SIGUSR2 $( cat $pid ) 2>/dev/null => kill -s SIGUSR2 $( cat $pid ) 2>/dev/null || true

Details

Version
VyOS 1.4-rolling-202305030317
Is it a breaking change?
Unspecified (possibly destroys the router)
Issue type
Unspecified (please specify)

Event Timeline

Viacheslav claimed this task.
Viacheslav moved this task from Open to Finished on the VyOS 1.4 Sagitta board.

Fixed with rewriting to systemd unit vyos-wan-load-balance.service