This is a crash with full tracebcak on 5.3.2 on FreeBSD 6.2/amd64 in log_handler_file(). We see it at the top of the hour when newsyslog(8) rotates files and passes SIGHUP to various daemons. Issues #1473289 and #1681977 come to mind.
Bill Moran remarks: "The problem is (at least) one stack frame higher, as the inaccessible memory pointer was passed _to_ this function." ~BAS [EMAIL PROTECTED] /foo]$ sudo gdb /usr/local/sbin/snmpd /foo/snmpd.core GNU gdb 6.1.1 [FreeBSD] Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "amd64-marcel-freebsd"... Core was generated by `snmpd'. Program terminated with signal 3, Quit. Reading symbols from /usr/local/lib/libnetsnmpmibs.so.10...done. Loaded symbols for /usr/local/lib/libnetsnmpmibs.so.10 Reading symbols from /usr/local/lib/libnetsnmpagent.so.10...done. Loaded symbols for /usr/local/lib/libnetsnmpagent.so.10 Reading symbols from /usr/local/lib/libnetsnmphelpers.so.10...done. Loaded symbols for /usr/local/lib/libnetsnmphelpers.so.10 Reading symbols from /usr/lib/libwrap.so.4...done. Loaded symbols for /usr/lib/libwrap.so.4 Reading symbols from /usr/local/lib/libnetsnmp.so.10...done. Loaded symbols for /usr/local/lib/libnetsnmp.so.10 Reading symbols from /lib/libcrypto.so.4...done. Loaded symbols for /lib/libcrypto.so.4 Reading symbols from /lib/libkvm.so.3...done. Loaded symbols for /lib/libkvm.so.3 Reading symbols from /lib/libdevstat.so.5...done. Loaded symbols for /lib/libdevstat.so.5 Reading symbols from /usr/local/lib/perl5/5.8.8/mach/CORE/libperl.so...done. Loaded symbols for /usr/local/lib/perl5/5.8.8/mach/CORE/libperl.so Reading symbols from /lib/libm.so.4...done. Loaded symbols for /lib/libm.so.4 Reading symbols from /lib/libcrypt.so.3...done. Loaded symbols for /lib/libcrypt.so.3 Reading symbols from /lib/libutil.so.5...done. Loaded symbols for /lib/libutil.so.5 Reading symbols from /lib/libc.so.6...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /libexec/ld-elf.so.1...done. Loaded symbols for /libexec/ld-elf.so.1 #0 0x000000007e7f8a2c in write () from /lib/libc.so.6 (gdb) bt #0 0x000000007e7f8a2c in write () from /lib/libc.so.6 #1 0x000000007e7f8350 in __swrite () from /lib/libc.so.6 #2 0x000000007e7f8464 in _swrite () from /lib/libc.so.6 #3 0x000000007e7f78ad in __sflush () from /lib/libc.so.6 #4 0x000000007e7f77c8 in fflush () from /lib/libc.so.6 #5 0x000000007dbe68f2 in log_handler_file (logh=0x509080, pri=7, str=0x7fffffffb250 "compare:index: ") at snmp_logging.c:1081 #6 0x000000007dbe6a37 in snmp_log_string (priority=7, str=0x7fffffffb250 "compare:index: ") at snmp_logging.c:1143 #7 0x000000007dbe6b10 in snmp_vlog (priority=7, format=0x7dc1b828 "%s: ", ap=0x7fffffffb690) at snmp_logging.c:1209 #8 0x000000007dbe3605 in debugmsg (token=0x7dc20d35 "compare:index", format=0x7dc1b828 "%s: ") at snmp_debug.c:334 #9 0x000000007dbe3dbc in debugmsgtoken (token=0x7dc20d35 "compare:index", format=0x7dc20d43 "compare ") at snmp_debug.c:529 #10 0x000000007dc0d7e3 in netsnmp_compare_netsnmp_index (lhs=0x6ed540, rhs=0x6ed5a0) at container.c:422 #11 0x000000007dc0dcdc in array_qsort (data=0x6ff000, first=0, last=3, f=0x7dc0d750 <netsnmp_compare_netsnmp_index>) at container_binary_array.c:69 #12 0x000000007dc0ddd3 in array_qsort (data=0x6ff000, first=0, last=6, f=0x7dc0d750 <netsnmp_compare_netsnmp_index>) at container_binary_array.c:89 #13 0x000000007dc0ded0 in Sort_Array (c=0x64b600) at container_binary_array.c:110 #14 0x000000007dc0e5bd in netsnmp_binary_array_get (c=0x64b600, key=0x7fffffffb9d0, exact=1) at container_binary_array.c:241 #15 0x000000007dc0e562 in _ba_find (container=0x64b600, data=0x7fffffffb9d0) at container_binary_array.c:513 #16 0x000000007d9756fe in netsnmp_tdata_row_get_byoid (table=0x63c500, searchfor=0x0, searchfor_len=0) at table_tdata.c:469 #17 0x000000007d6b80d3 in mteObjects_createEntry (owner=0x7d6cf8f3 "snmpd.conf", oname=0x7fffffffcda0 "_BdskTable", index=2, flags=20) at disman/event/mteObjects.c:154 #18 0x000000007d6b8210 in mteObjects_addOID (owner=0x7d6cf8f3 "snmpd.conf", oname=0x7fffffffcda0 "_BdskTable", index=2, oid_name_buf=0x7fffffffcdd0 "dskErrorMsg", wild=1) at disman/event/mteObjects.c:207 #19 0x000000007d6af255 in parse_mteMonitor (token=0x7d6cf78b "monitor", line=0x7d6cfec8 "-o dskPath -o dskErrorMsg \"dskTable\" dskErrorFlag != 0") at disman/event/mteTriggerConf.c:378 #20 0x000000007d6b071e in parse_default_mteMonitors (token=0x7fffffffe090 "defaultMonitors", line=0x7fffffffe4a0 "yes") at disman/event/mteTriggerConf.c:761 #21 0x000000007dbdf2ea in run_config_handler (lptr=0x632d00, token=0x7fffffffe090 "defaultMonitors", cptr=0x7fffffffe4a0 "yes", when=0) at read_config.c:506 #22 0x000000007dbe014a in read_config (filename=0x7fffffffe960 "/usr/local/etc/snmp/snmpd.conf", line_handler=0x509100, when=0) at read_config.c:796 #23 0x000000007dbe0f0e in read_config_files_in_path (path=0x64cb80 "/usr/local/etc/snmp:/usr/local/share/snmp:/usr/local/lib/snmp:/home/smcafee/.snmp", ctmp=0x50b100, when=0, perspath=0x652410 "/var/net-snmp", persfile=0x0) at read_config.c:1118 #24 0x000000007dbe1057 in read_config_files (when=0) at read_config.c:1199 #25 0x000000007dbe0567 in read_configs () at read_config.c:864 #26 0x000000007dbbb7cb in init_snmp (type=0x406418 "snmpd") at snmp_api.c:839 #27 0x0000000000404886 in main (argc=4, argv=0x7fffffffecb0) at snmpd.c:905 -------- Forwarded Message -------- > From: Brian A. Seklecki <[EMAIL PROTECTED]> > To: net-snmp-users@lists.sourceforge.net > Subject: 5.3.x segfaults with signal handling and log files? > Date: Mon, 07 Apr 2008 11:02:50 -0400 > > All: > > Are there any known issues with signal handling and log file rotation? > > I'm looking through a traceback on a debug build of 5.3.2. > > We run our agents -Ls[facil#] -- but I'm seeing calls to > log_handler_file() in GBD. Very strange. > > I seem to recall snmpd(8) wanting to write to /var/log/snmpd.log even > when -Ls > > I can provide a full traceback and core file if needed -- but I wanted > to check if anyone knew of a major outstanding bug report? > > ~BAS -- Brian A. Seklecki <[EMAIL PROTECTED]> Collaborative Fusion, Inc. ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone _______________________________________________ Net-snmp-users mailing list Net-snmp-users@lists.sourceforge.net Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users