Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 2 Feb 2001 06:15:11 -0800 (PST)
From:      Luigi Rizzo <rizzo@aciri.org>
To:        ishizuka@ish.org (Masachika ISHIZUKA)
Cc:        freebsd-net@FreeBSD.ORG
Subject:   Re: packet loss when 'ipfw pipe list' with dummynet and bridge
Message-ID:  <200102021415.f12EFBs70349@iguana.aciri.org>
In-Reply-To: <20010202191214B.ishizuka@onion.ish.org> from Masachika ISHIZUKA at "Feb 2, 2001  7:12:14 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
>   I use dummynet and bridge on FreeBSD 4.2-Stable to see traffic
> statics on Celeron 466MHz with 256 mega bytes ram as follows.
> 
> ipfw pipe 1 config mask dst-ip 0xffffffff buckets 1024
> ipfw pipe 2 config mask src-ip 0xffffffff buckets 1024
> ipfw add pipe 1 all from any to any bridged via fxp0 in
> ipfw add pipe 2 all from any to any bridged via fxp1 in
> 
>   It is collected about 10,000 addresses each pipes.
>   When I typed 'ipfw pipe list', packet loss occur.
> Packet loss occur only recent 4.2-Stable with splimp()
> instead of splnet().  When I replaced splimp() of dummynet_get()
> in ip_dummynet.c with slpnet(), packet loss did not occur,
> but sometimes panic occur.
>   Is there any way to stop packet loss.

unfortunately the "pipe list" has to navigate through a list of
pipe/flow/queue descriptors to report its output, and at the moment
it does this with interrupts disabled to avoid that the data
structure changes while it is working.

A better approach would probably be to set a semaphore before
starting, and release it at the end, and keep interrupts enabled
during the transfer but make sure that no object is created or
deleted and no pointer is changed during the process.  You can
still risk loss (when e.g. you cannot create a new flow descriptor)
but better than the current method.

	cheers
	luigi
>   Sorry to my terrible English.
> 
> -- 
> ishizuka@ish.org
> 
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-net" in the body of the message
> 



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200102021415.f12EFBs70349>