Date: Wed, 12 Sep 2012 10:39:12 +0200 From: Miroslav Lachman <000.fbsd@quip.cz> To: Mikolaj Golub <to.my.trociny@gmail.com> Cc: freebsd-stable@freebsd.org Subject: Re: bsnmpd always died on HDD detach Message-ID: <50504A30.10501@quip.cz> In-Reply-To: <20120912055831.GA48849@gmail.com> References: <504D10A7.1070701@quip.cz> <20120910054459.GA57302@gmail.com> <504DFD37.60105@quip.cz> <20120910203511.GA27221@gmail.com> <504F9C39.2070107@quip.cz> <20120912055831.GA48849@gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Mikolaj Golub wrote: > On Tue, Sep 11, 2012 at 10:16:57PM +0200, Miroslav Lachman wrote: > >> (gdb) bt >> #0 0x0000000801046cba in refresh_disk_storage_tbl () from >> /usr/lib/snmp_hostres.so >> #1 0x00000008010478bd in refresh_device_tbl () from >> /usr/lib/snmp_hostres.so >> #2 0x0000000801047be6 in start_device_tbl () from /usr/lib/snmp_hostres.so >> #3 0x000000080065fad5 in poll_dispatch () from /lib/libbegemot.so.4 >> #4 0x000000000040616a in main () >> >> >> Is it all you need? (I don't know how to use gdb) >> >> It is on FreeBSD 8.3-RELEASE #0: Mon Apr 9 21:23:18 UTC 2012 >> root@mason.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC amd64 > > Not sure we can get more than provided from this core as snmp_hostres > is not built with debugging symbols. You can try rebuilding > snmp_hostres with -g option, intalling and running gdb/bt again > > DEBUG_FLAGS=-g make -C /usr/src/usr.sbin/bsnmpd/modules/snmp_hostres clean all install > > AFAIK it might work or not. If it does not then wait for another crash :-) I don't know it is better or not. All I can say is: "it's different" ;) # gdb /usr/sbin/bsnmpd /bsnmpd.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"...(no debugging symbols found)... Core was generated by `bsnmpd'. Program terminated with signal 11, Segmentation fault. Reading symbols from /lib/libbegemot.so.4...(no debugging symbols found)...done. Loaded symbols for /lib/libbegemot.so.4 Reading symbols from /lib/libbsnmp.so.5...(no debugging symbols found)...done. Loaded symbols for /lib/libbsnmp.so.5 Reading symbols from /usr/lib/libwrap.so.6...(no debugging symbols found)...done. Loaded symbols for /usr/lib/libwrap.so.6 Reading symbols from /lib/libc.so.7...(no debugging symbols found)...done. Loaded symbols for /lib/libc.so.7 Reading symbols from /usr/lib/snmp_mibII.so...(no debugging symbols found)...done. Loaded symbols for /usr/lib/snmp_mibII.so Reading symbols from /usr/lib/snmp_pf.so...(no debugging symbols found)...done. Loaded symbols for /usr/lib/snmp_pf.so Reading symbols from /usr/lib/snmp_hostres.so...done. Loaded symbols for /usr/lib/snmp_hostres.so Reading symbols from /lib/libkvm.so.5...done. Loaded symbols for /lib/libkvm.so.5 Reading symbols from /usr/lib/libdevinfo.so.5...done. Loaded symbols for /usr/lib/libdevinfo.so.5 Reading symbols from /lib/libm.so.5...done. Loaded symbols for /lib/libm.so.5 Reading symbols from /lib/libgeom.so.5...done. Loaded symbols for /lib/libgeom.so.5 Reading symbols from /usr/lib/libmemstat.so.3...done. Loaded symbols for /usr/lib/libmemstat.so.3 Reading symbols from /lib/libbsdxml.so.4...done. Loaded symbols for /lib/libbsdxml.so.4 Reading symbols from /lib/libsbuf.so.5...done. Loaded symbols for /lib/libsbuf.so.5 Reading symbols from /libexec/ld-elf.so.1...done. Loaded symbols for /libexec/ld-elf.so.1 #0 0x0000000801046cba in disk_query_disk (entry=0x0) at hostres_diskstorage_tbl.c:241 241 partition_tbl_handle_disk(entry->index, entry->dev_name); (gdb) bt #0 0x0000000801046cba in disk_query_disk (entry=0x0) at hostres_diskstorage_tbl.c:241 #1 0x0000000801dd6a00 in ?? () #2 0x0000000801dd6600 in ?? () #3 0x0000000000000000 in ?? () #4 0x0000000801048230 in device_entry_create (name=0x0, location=0x800c14ee0 "0", descr=0x8010482a6 "") at hostres_device_tbl.c:217 #5 0x0000000801dd7800 in ?? () #6 0x0000000801dd7800 in ?? () #7 0x0000000801dd7400 in ?? () #8 0x0000000000000000 in ?? () #9 0x0000000801048230 in device_entry_create (name=0x801dd7c00 "", location=0x801048230 "˙˙I\213|$8čŕ\201˙˙L\211çčŘ\201˙˙é\035ţ˙˙H\215\025", descr=0x8010482a6 "") at hostres_device_tbl.c:217 #10 0x0000000801dd4a00 in ?? () #11 0x0000000801dd4a00 in ?? () #12 0x0000000801dd1a00 in ?? () #13 0x0000000000000000 in ?? () #14 0x0000000801048230 in device_entry_create (name=0x801dd8400 "", location=0x801048230 "˙˙I\213|$8čŕ\201˙˙L\211çčŘ\201˙˙é\035ţ˙˙H\215\025", descr=0x8010482a6 "") at hostres_device_tbl.c:217 #15 0x0000000801dd1800 in ?? () #16 0x0000000801dd1800 in ?? () #17 0x0000000800c00ea8 in ?? () #18 0x000000000051b1c8 in ?? () #19 0x0000000800c00938 in ?? () #20 0x000000000051b258 in ?? () #21 0x0000000801dc8a00 in ?? () #22 0x00000008009f7be9 in free () from /lib/libc.so.7 #23 0x0000000000000000 in ?? () #24 0x00007fffffffed98 in ?? () #25 0x00000008010478bd in device_entry_delete () at hostres_device_tbl.c:266 #26 0x00000000005187d0 in snmp_error () #27 0x0000000801047be6 in op_hrDeviceTable (ctx=Variable "ctx" is not available. ) at hostres_device_tbl.c:671 #28 0x000000000051b840 in ?? () #29 0x000000000051b830 in ?? () #30 0x0000000000000000 in ?? () #31 0x00007fffffffc360 in ?? () #32 0x000000000051b830 in ?? () #33 0x0000000000000000 in ?? () #34 0x00000008009efbd2 in _pthread_mutex_init_calloc_cb () from /lib/libc.so.7 #35 0x00000008009f2d32 in _malloc_prefork () from /lib/libc.so.7 #36 0x00000008009f6e1f in realloc () from /lib/libc.so.7 #37 0x0000000800e0b441 in mib_if_is_dyn () from /usr/lib/snmp_mibII.so #38 0x0000000000000000 in ?? () #39 0x00007fffffffc5cc in ?? () #40 0x0000000000000001 in ?? () #41 0x00007fffffffc5e0 in ?? () #42 0x31fa39e2fac72819 in ?? () #43 0x0000000000000001 in ?? () #44 0x000000080065fad5 in poll_dispatch () from /lib/libbegemot.so.4 #45 0x000000000040616a in main () I hope it helps you to debug this problem. Miroslav Lachman
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?50504A30.10501>