Martin, I don't know how you're capturing this, but it's all but impossible
to read w/o the line breaks...

What I see is this:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 6151 (LWP 9821)] 0x40275f72 in pcap_snapshot () from
/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52

and

#0  0x40275f72 in pcap_snapshot () from
/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52 No symbol table info
available.

#1  0x40276969 in pcap_compile () from
/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52 No symbol table info
available.

#2  0x0804d005 in doChangeFilter (len=26) at admin.c:637
      len = 1076605344
        i = 1
        idx = 26
        badChar = 0
        fcode = {bf_len = 14, bf_insns = 0x861ae58}
        currentFilterExpressionSav = 0x8462858 ""
        buf = "<B>\000...
        postData = "filter\000host+193.16.118.209", '\000' <repeats 229 times>
        key = 0xbedfe95c "\016"
        err = 0x0

So, questions:

1. It dies when you change the pcap filter, correct?

2. What version of libpcap and where did you get it?

3. Using gdb do some prints so we can see what you're changing it TO.  Also,
I guess it would be useful to see the values of the other variables in that
piece of code:

    for(i=0; i<myGlobals.numDevices; i++) {
      if((!myGlobals.device[i].virtualDevice)&&(err==NULL)) {
        if((pcap_compile(myGlobals.device[i].pcapPtr, &fcode,
myGlobals.currentFilterExpression, 1,
                        myGlobals.device[i].netmask.s_addr) < 0)

(gdb) print i
(gdb) print myGlobals.device[i].virtualDevice
(gdb) print myGlobals.currentFilterExpression
(gdb) myGlobals.device[i].netmask.s_addr


-----Burton


-----Original Message-----
From: Martin Hierling [mailto:mad@;cc.fh-lippe.de]On Behalf Of Martin
Hierling
Sent: Thursday, October 31, 2002 6:45 AM
To: Burton M. Strauss III
Subject: Re: [Ntop] Sig 11 when changing Filter


Hi Burton,

hier it comes ...

> Please run under gdb and use the bt full to capture the trace.  That way
we
> see line # offsets not hex (which is dependent upon the exact version you
> have, the ./configure and compile parameters, etc.)


pretty much!

regards Martin

�Script� wurde gestartet: Thu Oct 31 13:38:41 2002
suedfall:/home/martin/temp/ntop-cvs/ntop # LD_LIBRARY_PATH=.libs/ gdb
.libs/lt-ntop  GNU gdb 5.1.1 Copyright 2002 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 "i386-suse-linux"... (gdb) set args --local-subnets
"193.16.112.0/255.255.240.0" -K --user root --interface lo --trace-level
3 -w 127.0.0.1:3000  -E (gdb) run Starting program:
/home/martin/temp/ntop-cvs/ntop/.libs/lt-ntop --local-subnets
"193.16.112.0/255.255.240.0" -K --user root --interface lo --trace-level
3 -w 127.0.0.1:3000  -E [New Thread 1024 (LWP 9810)] Wait please: ntop is
coming up... 31/Oct/2002 13:39:01 Initializing IP services... SSL is present
but https is disabled: use -W <https port> for enabling it 31/Oct/2002
13:39:01 Initializing GDBM... 31/Oct/2002 13:39:02 Initializing network
devices... 31/Oct/2002 13:39:02 ntop v.2.1.52 MT (SSL) [i686-suse-linux]
(10/23/02 03:03:05 PM build) 31/Oct/2002 13:39:02 Listening on [lo]
31/Oct/2002 13:39:02 Copyright 1998-2002 by Luca Deri <[EMAIL PROTECTED]>
31/Oct/2002 13:39:02 Get the freshest ntop from http://www.ntop.org/
31/Oct/2002 13:39:02 Initializing... 31/Oct/2002 13:39:02 Truncated network
size to 1024 hosts (real netmask 255.0.0.0) 31/Oct/2002 13:39:02 Loading
plugins (if any)... 31/Oct/2002 13:39:02 Searching plugins in ./plugins
31/Oct/2002 13:39:02 Welcome to NetFlow. (C) 2002 by Luca Deri. 31/Oct/2002
13:39:03 WARNING: unable to local plugin './plugins/rrdPlugin.so' entry
function [/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52: undefined
symbol: PluginEntryFctn] 31/Oct/2002 13:39:04 Welcome to
LastSeenWatchPlugin. (C) 1999 by Andrea Marangoni. 31/Oct/2002 13:39:05
Welcome to nfsWatchPlugin. (C) 1999 by Luca Deri. 31/Oct/2002 13:39:05
Welcome to sFlowPlugin. (C) 2002 by Luca Deri. 31/Oct/2002 13:39:06 Welcome
to PDAPlugin. (C) 2001-2002 by L.Deri and W.Brock 31/Oct/2002 13:39:07
Welcome to icmpWatchPlugin. (C) 1999 by Luca Deri. 31/Oct/2002 13:39:07
Device 0(lo) is loopback, treating as DLT_NULL 31/Oct/2002 13:39:08
Resetting traffic statistics... [New Thread 2049 (LWP 9814)] [New Thread
1026 (LWP 9815)] 31/Oct/2002 13:39:09 Started thread (1026) for lsof
support. [New Thread 2051 (LWP 9817)] 31/Oct/2002 13:39:09 Started thread
(2051) for network packet analyser. [New Thread 3076 (LWP 9818)] 31/Oct/2002
13:39:09 Started thread (3076) for idle hosts detection. [New Thread 4101
(LWP 9819)] 31/Oct/2002 13:39:09 Started thread (4101) for DNS address
resolution. 31/Oct/2002 13:39:09 Initializing plugins (if any)...
31/Oct/2002 13:39:09 NetFlow collector listening on port 4446. 31/Oct/2002
13:39:09 NetFlow export disabled [New Thread 5126 (LWP 9820)] 31/Oct/2002
13:39:09 Welcome to NetFlow: listening on UDP port 4446... 31/Oct/2002
13:39:09 Started thread (0) for netFlow. 31/Oct/2002 13:39:09 Converted
address '127.0.0.1'... binding to the specific interface! 31/Oct/2002
13:39:09 Waiting for HTTP connections on 127.0.0.1 port 3000... [New Thread
6151 (LWP 9821)] 31/Oct/2002 13:39:09 Started thread (6151) for web server.
31/Oct/2002 13:39:09 Sniffying... [New Thread 7176 (LWP 9822)] 31/Oct/2002
13:39:09 Started thread (7176) for network packet sniffing on lo.
31/Oct/2002 13:39:10 Received NetFlow packet (len=1464) (deviceId=1)
31/Oct/2002 13:39:11 Received NetFlow packet (len=1464) (deviceId=1)
31/Oct/2002 13:39:11 Extending hash size [newSize=512][deviceId=1]
31/Oct/2002 13:39:11 Received NetFlow packet (len=1464) (deviceId=1)
31/Oct/2002 13:39:31 Changing the kernel (libpcap) filter... 31/Oct/2002
13:39:31 Set filter "host 193.16.118.209" on myGlobals.device lo.
31/Oct/2002 13:39:31 Received NetFlow packet (len=1464) (deviceId=1)
Program received signal SIGSEGV, Segmentation fault. [Switching to Thread
6151 (LWP 9821)] 0x40275f72 in pcap_snapshot () from
/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52 (gdb) list 711
return(userSpecified); 712      } 713    714    /*
************************************ */ 715      716    /* That's the meat */ 717
#ifdef WIN32 718        int ntop_main(int argc, char *argv[]) { 719     #else 720      
 int
main(int argc, char *argv[]) { (gdb) info stack #0  0x40275f72 in
pcap_snapshot () from
/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52 #1  0x40276969 in
pcap_compile () from /home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52
#2  0x0804d005 in doChangeFilter (len=26) at admin.c:637 #3  0x40040152 in
returnHTTPPage (pageName=0xbedff555 "doChangeFilter", postLen=26,
from=0xbedff75c, httpRequestedAt=0xbedff40c,      usedFork=0xbedff408,
agent=0xbedff414 "Mozilla/4.79 [de] (X11; U; Linux 2.4.18 i686)") at
http.c:1211 #4  0x40042e40 in handleHTTPrequest (from={s_addr = 2130706433})
at http.c:2119 #5  0x4006e5ed in handleSingleWebConnection
(fdmask=0xbedffa64) at webInterface.c:3608 #6  0x4006e2d5 in
handleWebConnections (notUsed=0x0) at webInterface.c:3471 #7  0x404b0e67 in
pthread_start_thread () from /lib/libpthread.so.0 #8  0x404b0eb5 in
pthread_start_thread_event () from /lib/libpthread.so.0 (gdb) bt full #0
0x40275f72 in pcap_snapshot () from
/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52 No symbol table info
available. #1  0x40276969 in pcap_compile () from
/home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52 No symbol table info
available. #2  0x0804d005 in doChangeFilter (len=26) at admin.c:637     len =
1076605344      i = 1   idx = 26        badChar = 0     fcode = {bf_len = 14, bf_insns 
=
0x861ae58}      currentFilterExpressionSav = 0x8462858 ""       buf =
"<B>\000op!<\002\000\000\000��+@listening on [lo,NetFlow-device]\nwithout a
kernel (libpcap) filtering expression\n\000-linux] (10/23/02
\216�J@\230\233`@\004\000\000\000T�߾PEK@\230\233`@\000\000\000\000\024�߾4�
S@\034�߾\000\000\000\000\004\000\000\000VpS@\230\233`@T�߾��߾�\204[@\230\2
33`@\000\020\001\000T�߾\222�U@"...     postData =
"filter\000host+193.16.118.209", '\000' <repeats 229 times>     key =
0xbedfe95c "\016"       err = 0x0 #3  0x40040152 in returnHTTPPage
(pageName=0xbedff555 "doChangeFilter", postLen=26, from=0xbedff75c,
httpRequestedAt=0xbedff40c,      usedFork=0xbedff408, agent=0xbedff414
"Mozilla/4.79 [de] (X11; U; Linux 2.4.18 i686)") at http.c:1211         from =
(struct in_addr *) 0x0  httpRequestedAt = (struct timeval *) 0x0
questionMark = 0x0      sortedColumn = 0        printTrailer = 0        idx = 2        
 errorCode =
0       pageNum = 0     statbuf = {st_dev = 8464411798187430247, __pad1 = 43509,
st_ino = 2664881021, st_mode = 2352372305, st_nlink = 3891262249,    st_uid
= 2327268534, st_gid = 606702616, st_rdev = 15927371510011548475, __pad2 =
33235, st_size = -583010849, st_blksize = -1617835905,    st_blocks =
455647, st_atime = -553086720, __unused1 = 3236551211, st_mtime =
1547986816, __unused2 = 3019668260, st_ctime = -215790370,  ---Type <return>
to continue, or q <return> to quit---   __unused3 = 1158994868, __unused4 =
3725275866, __unused5 = 1328761697}     fd = (FILE *) 0x0       tmpStr =
"/home/martin/local/share/ntop/html/doChangeFilter\000\000\000@\034S\b��߾DZ
K@\000\000\000\000\000\000\000\000\001\000\000\000�WK@\\�K@Pw`@8\034S\bb�J@�
\000\000\000\000\000\000\000��߾\000\000\000\000=\031K@\000\000\000\000��߾�
K@`w`@@s`@8\034S\b�\037K@\230\233`@@s`@8\034S\b
gU@@\034S\b\000\000\000\000$�߾k�U@Pw`@@s`@$�߾S�U@\230\233`@��߾"...
domainNameParm = 0x0    revertOrder = 0         rc = -1092619956        t = {tm_sec =
139664448, tm_min = 0, tm_hour = 1079344741, tm_mday = 1080073112, tm_mon =
139664448, tm_year = -1092619900,    tm_wday = 1079340982, tm_yday =
139664448, tm_isdst = 1074839552, tm_gmtoff = 4096,    tm_zone = 0x40556f86
"\213F\034\211F\004\211F\f\211F\b\211F\030\211F\024\017�VF\211F\020\203��\21
3\214\026\224"} #4  0x40042e40 in handleHTTPrequest (from={s_addr =
2130706433}) at http.c:2119     skipLeading = -1        postLen = 26    usedFork = 0
requestedURL = "/doChangeFilter", '\000' <repeats 496 times>    pw =
"YWRtaW46YWRtaW4=", '\000' <repeats 47 times>   agent = "Mozilla/4.79 [de]
(X11; U; Linux 2.4.18 i686)", '\000' <repeats 210 times>        rc = 0  i
= -1092619256   httpRequestedAt = {tv_sec = 1036067971, tv_usec = 159677}
gzipBytesSent = 0 #5  0x4006e5ed in handleSingleWebConnection
(fdmask=0xbedffa64) at webInterface.c:3608      fdmask = (fd_set *) 0xbedffa64
from = {sin_family = 2, sin_port = 53189, sin_addr = {s_addr = 16777343},
sin_zero = "\023\002\000\000����"}      from_len = 16 #6  0x4006e2d5 in
handleWebConnections (notUsed=0x0) at webInterface.c:3471       rc = 0  mask =
{__fds_bits = {262144, 0 <repeats 31 times>}}   mask_copy = {__fds_bits =
{262144, 0 <repeats 31 times>}} ---Type <return> to continue, or q <return>
to quit---      topSock = 18 #7  0x404b0e67 in pthread_start_thread () from
/lib/libpthread.so.0 No symbol table info available. #8  0x404b0eb5 in
pthread_start_thread_event () from /lib/libpthread.so.0 No symbol table info
available. (gdb) kill Kill the program being debugged? (y or n) y �Script�
beendet: Thu Oct 31 13:41:11 2002




>
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:ntop-admin@;unipi.it]On Behalf Of
> Martin Hierling
> Sent: Thursday, October 24, 2002 3:44 AM
> To: NTop Liste
> Subject: [Ntop] Sig 11 when changing Filter
>
>
> Hi,
>
> when i try to change a filter with the browser i get sig11 ;-( (not really
> me, but ntop). It happens with stable and CVS version.
>
> 24/Oct/2002 10:37:35 Changing the kernel (libpcap) filter...
> 24/Oct/2002 10:37:35 Set filter "host 193.16.xxx.xxx" on myGlobals.device
> lo.
> 24/Oct/2002 10:37:35 ntop caught signal 11
> 24/Oct/2002 10:37:35
>
> *****ntop error: Signal(11)
> 24/Oct/2002 10:37:35
>      backtrace is:
> 24/Oct/2002 10:37:35            1. /lib/libpthread.so.0 [0x404b3a74]
> 24/Oct/2002 10:37:35            2. /lib/libc.so.6 [0x40515a38]
> 24/Oct/2002 10:37:35            3.
> /home/martin/temp/ntop-cvs/ntop/.libs/libntop-2.1.so.52(pcap_compile+0x7d)
> [0x40276969]
> 24/Oct/2002 10:37:35            4. lt-ntop(doChangeFilter+0x325)
[0x804d005]
> 24/Oct/2002 10:37:35            5.
> /home/martin/temp/ntop-cvs/ntop/.libs/libntopreport-2.1.so.52 [0x40040152]
> 24/Oct/2002 10:37:35            6.
>
/home/martin/temp/ntop-cvs/ntop/.libs/libntopreport-2.1.so.52(handleHTTPrequ
> est+0x270) [0x40042e40]
> 24/Oct/2002 10:37:35            7.
> /home/martin/temp/ntop-cvs/ntop/.libs/libntopreport-2.1.so.52 [0x4006e5ed]
> 24/Oct/2002 10:37:35            8.
>
/home/martin/temp/ntop-cvs/ntop/.libs/libntopreport-2.1.so.52(handleWebConne
> ctions+0x205) [0x4006e2d5]
> 24/Oct/2002 10:37:35            9. /lib/libpthread.so.0 [0x404b0e67]
> 24/Oct/2002 10:37:35           10. /lib/libc.so.6(__clone+0x3a)
[0x405be72a]
> 24/Oct/2002 10:37:35 Cleaning up...
> 24/Oct/2002 10:37:35 Waiting until threads terminate...
> 24/Oct/2002 10:37:36 Received NetFlow packet (len=1464) (deviceId=1)
> 24/Oct/2002 10:37:39 Freeing hash host instances... (2 device(s) to save)
> 24/Oct/2002 10:37:39 326 instances freed
> 24/Oct/2002 10:37:39 Freeing hash host instances... (2 device(s) to save)
> 24/Oct/2002 10:37:39 0 instances freed
> 24/Oct/2002 10:37:39 Unloading plugins (if any)...
> 24/Oct/2002 10:37:39 Thanks for using icmpWatch...
> 24/Oct/2002 10:37:39 Done.
> 24/Oct/2002 10:37:39 Thanks for using PDAWatch...
> 24/Oct/2002 10:37:39 Done.
> 24/Oct/2002 10:37:39 Thanks for using ntop NetFlow
> 24/Oct/2002 10:37:39 Done.
> 24/Oct/2002 10:37:39 Cisco NetFlow exporter terminated.
>
>
> I am starting with:
> ./ntop --local-subnets "193.16.112.0/255.255.240.0" -K --user
> martin --interface lo --trace-level 3 -w 127.0.0.1:3000
>
> only to mention it.
>
> regards Martin
>
> --
> ----------------------------------------------------------------
>   A big enough hammer fixes anything
> ----------------------------------------------------------------
> _______________________________________________
> Ntop mailing list
> [EMAIL PROTECTED]
> http://listgateway.unipi.it/mailman/listinfo/ntop

--
Dipl.-Ing. Martin Hierling - S|KIM [it] FH Lippe und Hoexter
  Raum 343 - Liebigstr. 87 - 32657 Lemgo - Germany - Earth
  Tel.: +49-(0)5261 - 702-433 - Fax: +49-(0)5261 - 702-467
----------------------------------------------------------------
  A Smith & Wesson *ALWAYS* beats 4 Aces.
----------------------------------------------------------------

_______________________________________________
Ntop mailing list
[EMAIL PROTECTED]
http://listgateway.unipi.it/mailman/listinfo/ntop

Reply via email to