snmpd crash intermittently, when agent/subagent gets restarted with config changes.

SURYA T S <[email protected]>
Newsgroups gmane.network.net-snmp.devel
Message-ID <CAE53MwX8=wdOMiTNmgEun1r3kBqyDftmSgvdRW1GPMADwvsdSQ@mail.gmail.com>
Hi Team,


I am getting snmpd crash with below trace, during a system boot, or
snmp restart with config changes.
I am having netsnm version 5.7.2 running in my box.


Trace 1.
==========
Core was generated by `/usr/sbin/snmpd -Lo0-6d -f -x
/var/agentx/master_VRF_1 -p /var/run/openvswitch/'.

Program terminated with signal SIGSEGV, Segmentation fault.

#0  0x00007efc9524cf41 in snmp_sess_read2
(sessp=sessp@entry=0x7efc93cd2040, fdset=fdset@entry=0x7ffd4e23ef00)

    at /usr/src/debug/net-snmp/5.7.2-r1/net-snmp-5.7.2/snmplib/snmp_api.c:6200

6200             if (rc && pss->s_snmp_errno) {

(gdb) bt full

#0  0x00007efc9524cf41 in snmp_sess_read2
(sessp=sessp@entry=0x7efc93cd2040, fdset=fdset@entry=0x7ffd4e23ef00)

    at /usr/src/debug/net-snmp/5.7.2-r1/net-snmp-5.7.2/snmplib/snmp_api.c:6200

        psl = 0x7efc93cd2040

        pss = 0x0

        rc = -1

#1  0x00007efc9524cf8b in snmp_read2 (fdset=0x7ffd4e23ef00) at
/usr/src/debug/net-snmp/5.7.2-r1/net-snmp-5.7.2/snmplib/snmp_api.c:5799

        slp = 0x7efc93cd2040

#2  0x0000000000403ff5 in ?? ()

No symbol table info available.

#3  0x00007efc94e88740 in __libc_start_main (main=0x402600, argc=7,
argv=0x7ffd4e23f1c8, init=<optimized out>, fini=<optimized out>,
rtld_fini=<optimized out>,

    stack_end=0x7ffd4e23f1b8) at
/usr/src/debug/glibc/2.23-r0/git/csu/libc-start.c:289

        self = <optimized out>

        result = <optimized out>

        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {0,
-9062587388492096986, 4210992, 140725914431936, 0, 0,
9061704306574383654, 9205939935531391526},

              mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x4043f0,
0x7ffd4e23f1c8}, data = {prev = 0x0, cleanup = 0x0, canceltype =
4211696}}}

        not_first_call = <optimized out>

#4  0x0000000000404159 in ?? ()

No symbol table info available.



Trace 2:
=======

Core was generated by `/usr/sbin/snmpd -Lo0-6d -f -x
/var/agentx/master_swns -p /var/run/openvswitch/s'.

Program terminated with signal SIGSEGV, Segmentation fault.

#0  _sess_read (sessp=sessp@entry=0xa1,
fdset=fdset@entry=0xffffe9265ea0) at
/usr/src/debug/net-snmp/5.7.2-r1/net-snmp-5.7.2/snmplib/snmp_api.c:5825

5825        netsnmp_transport *transport = slp ? slp->transport : NULL;

(gdb) bt

#0  _sess_read (sessp=sessp@entry=0xa1,
fdset=fdset@entry=0xffffe9265ea0) at
/usr/src/debug/net-snmp/5.7.2-r1/net-snmp-5.7.2/snmplib/snmp_api.c:5825

#1  0x0000ffff9ee3769c in snmp_sess_read2 (sessp=sessp@entry=0xa1,
fdset=fdset@entry=0xffffe9265ea0) at
/usr/src/debug/net-snmp/5.7.2-r1/net-snmp-5.7.2/snmplib/snmp_api.c:6206

#2  0x0000ffff9ee376f4 in snmp_read2 (fdset=0xffffe9265ea0) at
/usr/src/debug/net-snmp/5.7.2-r1/net-snmp-5.7.2/snmplib/snmp_api.c:5808

#3  0x0000000000404584 in ?? ()



This issue is not continously reproducible but seeing intermittently,
when snmp agent/subagent restarts, and snmpwalk happens in the
background.
Please help me understand the issue further and help me with the
patch/ if this issue is already taken care in the upstream.


Thanks,
Surya
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.