Hi Thomas,
Please see the attachment.
Thanks.
Lan
-----Original Message-----
From: Thomas Anders [mailto:[EMAIL PROTECTED]
Sent: Monday, June 20, 2005 10:12 AM
To: Wu, Lan, ALABS
Subject: Re: snmptrapd memory leak ??
Wu, Lan, ALABS wrote:
> $ gdb /home/snmp/netsnmp/net-snmp-5.2.1/apps/snmptrapd core
[...]
>
"sparc-sun-solaris2.8"..."/home/snmp/netsnmp/net-snmp-5.2.1/apps/snmptra
> pd": not in executable format: File format not recognized
Give the path to the *install* location of snmptrapd, not to the
snmptrapd wrapper shell script from the source dir! Then repost to the
list.
+Thomas
--
Thomas Anders (thomas.anders at blue-cable.de)
$ pwd
/home/snmp/netsnmp/net-snmp-5.2.1/apps/.libs
$ file /home/snmp/netsnmp/net-snmp-5.2.1/apps/.libs/snmptrapd
/home/snmp/netsnmp/net-snmp-5.2.1/apps/.libs/snmptrapd: ELF 32-bit MSB
executable SPARC Version 1, dynamically linked, not stripped
$ apps/.libs/snmptrapd /home/snmp/snmpcol/bin/core <
GNU gdb 6.0
Copyright 2003 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 "sparc-sun-solaris2.8"...
Core was generated by `snmptrapd -f -F
%N|%w%q|%#y%#02m%#02l_%#02.2h%#02.2j%#02.2k|%A|%B|%-v\n -OTausQ'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /usr/local/lib/libnetsnmptrapd.so.5...done.
Loaded symbols for /usr/local/lib/libnetsnmptrapd.so.5
Reading symbols from /usr/local/lib/libnetsnmpagent.so.5...done.
Loaded symbols for /usr/local/lib/libnetsnmpagent.so.5
Reading symbols from /usr/local/lib/libnetsnmpmibs.so.5...done.
Loaded symbols for /usr/local/lib/libnetsnmpmibs.so.5
Reading symbols from /usr/local/lib/libnetsnmphelpers.so.5...done.
Loaded symbols for /usr/local/lib/libnetsnmphelpers.so.5
Reading symbols from /usr/local/lib/libnetsnmp.so.5...done.
Loaded symbols for /usr/local/lib/libnetsnmp.so.5
Reading symbols from /usr/lib/libdl.so.1...done.
Loaded symbols for /usr/lib/libdl.so.1
Reading symbols from /usr/lib/libkvm.so.1...done.
Loaded symbols for /usr/lib/libkvm.so.1
Reading symbols from /usr/local/ssl/lib/libcrypto.so.0.9.7...done.
Loaded symbols for /usr/local/ssl/lib/libcrypto.so.0.9.7
Reading symbols from /usr/lib/libkstat.so.1...done.
Loaded symbols for /usr/lib/libkstat.so.1
Reading symbols from /usr/lib/libelf.so.1...done.
Loaded symbols for /usr/lib/libelf.so.1
Reading symbols from /usr/lib/libm.so.1...done.
Loaded symbols for /usr/lib/libm.so.1
Reading symbols from /usr/lib/libnsl.so.1...done.
Loaded symbols for /usr/lib/libnsl.so.1
Reading symbols from /usr/lib/libsocket.so.1...done.
Loaded symbols for /usr/lib/libsocket.so.1
---Type <return> to continue, or q <return> to quit---
Reading symbols from /usr/lib/libadm.so.1...done.
Loaded symbols for /usr/lib/libadm.so.1
Reading symbols from /usr/lib/libc.so.1...done.
Loaded symbols for /usr/lib/libc.so.1
Reading symbols from /usr/local/lib/libgcc_s.so.1...done.
Loaded symbols for /usr/local/lib/libgcc_s.so.1
Reading symbols from /usr/lib/libmp.so.2...done.
Loaded symbols for /usr/lib/libmp.so.2
Reading symbols from /usr/platform/SUNW,Sun-Fire-880/lib/libc_psr.so.1...done.
Loaded symbols for /usr/platform/SUNW,Sun-Fire-880/lib/libc_psr.so.1
Reading symbols from /usr/lib/nss_files.so.1...done.
Loaded symbols for /usr/lib/nss_files.so.1
Reading symbols from /usr/lib/locale/en_US.ISO8859-15/en_US.ISO8859-15.so.2...
done.
Loaded symbols for /usr/lib/locale/en_US.ISO8859-15/en_US.ISO8859-15.so.2
#0 0xff196054 in sprint_realloc_integer (buf=0xffbeed08, buf_len=0xffbeed04,
out_len=0xffbeed00, allow_realloc=1, var=0x36fc0, enums=0x0, hint=0x0,
units=0x0) at mib.c:1333
1333 sprintf(str, "%ld", *var->val.integer);
(gdb) where
#0 0xff196054 in sprint_realloc_integer (buf=0xffbeed08, buf_len=0xffbeed04,
out_len=0xffbeed00, allow_realloc=1, var=0x36fc0, enums=0x0, hint=0x0,
units=0x0) at mib.c:1333
#1 0xff19a57c in sprint_realloc_variable (buf=0xffbeed08, buf_len=0xffbeed04,
out_len=0xffbeed00, allow_realloc=1, objid=0x0, objidlen=438352,
variable=0x36fc0) at mib.c:3237
#2 0xff375d6c in realloc_handle_trap_fmt (buf=0x0, buf_len=0xffbeed04,
out_len=0xffbeed00, allow_realloc=1, options=0x36fc0, pdu=0x6b050)
at snmptrapd_log.c:983
(gdb)