Paolo Lucente wrote:
> Hi Gert,
> take the virgin pmacct package. Configure it with the options you are
> used to. Don't care of the --enable-debug. Once you get the Makefile
> files, get through them and replace the following line:
>
> CFLAGS = -O2
>
> with
>
> CFLAGS = -g
>
> Unless you are not using gcc, it will work. Will disable optimizations
> (-O2) and include symbols for debugging (-g). Then, compile pmacct and
> you will get the executables ready for debugging.
>
> At this point, you can either attach gdb live to the process or analyze
> coredumps created by the new executables. Aaron just posted an example
> of what is useful for us, basically a backtrace ('bt' on gdb console).
>
> To get even an idea of what/where is crashing, you can run the daemon
> with the following options in your configuration:
>
> daemonize: false
> debug: true
>
> It will generate lot of output on your console. But usually it helps.
> Once you get this all, you can either opt to post some brief output
> on the list, or contact me privately (for longer outputs, coredumps,
> files, logs, etc.).
>
> Cheers,
> Paolo
>
>
> _______________________________________________
> pmacct-discussion mailing list
> http://www.pmacct.net/#mailinglists
>
Im running FreeBSD 6.1-Stable, my config is as follows:
daemonize: false
debug: true
interface: dc0
plugins: mysql
aggregate: src_host,dst_host,proto,flows
promisc: false
sql_passwd: ******
sql_refresh_time: 60
sql_history: 1m
sql_history_roundoff: mh
sql_table_version: 4
sql_db: pmacct
sql_table: acct_v4
sql_user: root
GDB bt gives:
#0 0x28213e5f in __vfprintf () from /lib/libc.so.6
#1 0x2820e84c in snprintf () from /lib/libc.so.6
#2 0x08075d2c in MY_count_ip_proto_handler (cache_elem=0x8307990,
idata=0xbfbdccf0, num=7, ptr_values=0xbfbdc85c, ptr_where=0xbfbdc858) at
sql_handlers.c:151
#3 0x0806eb86 in MY_cache_dbop (db=0x80af1d8, cache_elem=0x8307990,
idata=0xbfbdccf0) at mysql_plugin.c:287
#4 0x08074bae in sql_query (bed=0x80b7300, elem=0x8307990,
idata=0xbfbdccf0) at sql_common.c:1076
#5 0x0806f4d8 in MY_cache_purge (queue=0x8482000, index=8,
idata=0xbfbdccf0) at mysql_plugin.c:455
#6 0x08071d99 in sql_exit_gracefully (signum=2) at sql_common.c:603
#7 0xbfbfff94 in ?? ()
#8 0x00000002 in ?? ()
#9 0x00000000 in ?? ()
#10 0xbfbdcd80 in ?? ()
#11 0x00000002 in ?? ()
#12 0x08071cbc in sql_db_errmsg () at sql_common.c:582
#13 0x0805562b in load_plugins (req=0xbfbfe733) at plugin_hooks.c:162
#14 0x080528b4 in main (argc=3, argv=0xbfbfe8bc, envp=0xbfbfe8cc) at
pmacctd.c:394
It seems like i still need some symbols in some libs, these libs symbols
loaded(Looks like it):
Reading symbols from /usr/lib/libpcap.so.4...done.
Loaded symbols for /usr/lib/libpcap.so.4
Reading symbols from /usr/local/lib/mysql/libmysqlclient.so.14...done.
Loaded symbols for /usr/local/lib/mysql/libmysqlclient.so.14
Reading symbols from /lib/libm.so.4...done.
Loaded symbols for /lib/libm.so.4
Reading symbols from /lib/libz.so.3...done.
Loaded symbols for /lib/libz.so.3
Reading symbols from /lib/libc.so.6...done.
Loaded symbols for /lib/libc.so.6
Reading symbols from /lib/libcrypt.so.3...done.
Loaded symbols for /lib/libcrypt.so.3
Reading symbols from /libexec/ld-elf.so.1...done.
Loaded symbols for /libexec/ld-elf.so.1
What else can I do to help?
Thanks
Gert Burger
_______________________________________________
pmacct-discussion mailing list
http://www.pmacct.net/#mailinglists