After some debugging advice Luca, I think I found my issue:
printHostsTraffic() (report.c around line 130)
..
HostTraffic* tmpTable[HASHNAMESIZE];
..
tmpTable[numEntries++]=el;
..
In ntop.h: HASHNAMESIZE 4096
My network gets lots of traffic from unique hosts, and numEntries went beyond 4096 in
about 2 hours. I would get segfaults, most commonly pointing near returnHTTPPage().
My simple solution was to increase tmpTable size until I remember how malloc works so
I can make it dynamically sized.
Daniel
--------------------------------------------------------
From: "daniel" <[EMAIL PROTECTED]>
Date: Mon, 4 Dec 2000 19:40:52 -0600
Subject: Redhat 7, 03 Dec CVS core dump
To: <[EMAIL PROTECTED]>
Sender: [EMAIL PROTECTED]
First, my compliments to all developers involved for some great coding.
I downloaded from CVS on 03 Dec and compiled on Redhat 7, with a recompiled libpcap
0.4-2, stock gdbm-1.8.0. After a couple of hours, I get a segfault and this gdb
output:
#0 0x406895ce in __select() from /lib/libc.so.6
#1 0x40223414 in __DTOR_END__ () from ..ntop/.libs/libntop-1.3.so.2
#2 0x40189825 in pthread_start_thread (arg=0xbe7ffc00) at manager.c:274
It happens pretty regularly. I'm on a Pentium-II 200 machine with a 100Mb ethernet
and very heavy network traffic.
I'm rather new linux programming in general, and ntop specifically, so I don't expect
anyone to do my work for me :) but can anyone suggest a starting point for me?
Daniel
[EMAIL PROTECTED]