net-snmp-5.9.3-r0 - snmpd crashes after some period of use in alpine 3.15.6
Snmpd started crashing on us yesterday without a clear cause. However the crashes are now reproducible on our machine and happen around 5-15 minutes after launch. I have not yet tried rebooting the machine.
(gdb) run -p /var/run/snmpd.pid -LSwd -Lf /dev/null -f
Starting program: /usr/sbin/snmpd -p /var/run/snmpd.pid -LSwd -Lf /dev/null -f
Program received signal SIGSEGV, Segmentation fault.
get_meta (p=p@entry=0x7ffff77931b0 "!") at src/malloc/mallocng/meta.h:135
135 src/malloc/mallocng/meta.h: No such file or directory.
(gdb) bt
#0 get_meta (p=p@entry=0x7ffff77931b0 "!") at src/malloc/mallocng/meta.h:135
#1 0x00007ffff7f8ac2e in __libc_free (p=0x7ffff77931b0) at src/malloc/mallocng/free.c:105
#2 0x00007ffff7c76b74 in _ssll_for_each (c=<optimized out>, f=0x7ffff7d4e19c <__delete_missing_interface>, context=0x7ffff779e690) at container_list_ssll.c:281
#3 0x00007ffff7d4edae in ifTable_container_load (container=0x7ffff779e690) at mibgroup/if-mib/ifTable/ifTable_data_access.c:651
#4 0x00007ffff7f1746a in _cache_load (cache=0x7ffff7873860) at helpers/cache_handler.c:735
#5 0x00007ffff7c583c5 in run_alarms () at snmp_alarm.c:214
#6 0x0000555555559268 in receive () at snmpd.c:1351
#7 0x0000555555558845 in main (argc=<optimized out>, argv=<optimized out>) at snmpd.c:1083
Little time to investigate further, but the configuration is pretty sparse. (Replaced secrets.)
agentAddress udp:161
agentAddress udp6:161
view systemonly included .1.3.6.1.2.1.1
view systemonly included .1.3.6.1.2.1.25.1
view systemonly included .1.3.6.1.4.1.2021.7890.1
rocommunity public localhost
rocommunity abcde --some-ipv4--/24
rocommunity abcde --some-ipv4--
rocommunity6 abcde --some-ipv6--
rouser abcde
sysLocation ABCDE serverroom
sysContact admin@a.b.c
sysServices 72
proc mountd
proc ntalkd 4
proc sendmail 10 1
disk / 100000
load 12 10 5
iquerySecName internalUser
rouser internalUser