mirror of
https://github.com/openwrt/packages.git
synced 2026-12-05 13:15:30 +04:00
The LuCI VRRP status page (luci-app-keepalived) stays empty because 'ubus
call keepalived dump' always returns '{}'. The rpcd plugin asks keepalived
to write /tmp/keepalived.json, but this never works:
- The JSON dump signal is hardcoded as 37. keepalived uses a signal based
on SIGRTMIN, so the number depends on the libc. On musl (aarch64) it is
36 ('keepalived --signum=JSON'), and signal 37 is ignored. Query the
number from keepalived instead.
- keepalived writes the file asynchronously from its event loop, after kill
has already returned. The script reads it immediately and finds nothing
(0/20 attempts on aarch64). After 10 ms it is always present (20/20).
Wait one second before reading it. Whole seconds work with every busybox
'sleep' build.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Signed-off-by: Alexander Wilhelm <alexander.wilhelm@westermo.com>