From owner-freebsd-net@FreeBSD.ORG Wed May 24 23:38:48 2006 Return-Path: X-Original-To: freebsd-net@freebsd.org Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 69CE316A444 for ; Wed, 24 May 2006 23:38:48 +0000 (UTC) (envelope-from benjamin@cactus.org) Received: from cactus.org (linux.cactus.org [66.118.232.151]) by mx1.FreeBSD.org (Postfix) with SMTP id 007EF43D45 for ; Wed, 24 May 2006 23:38:47 +0000 (GMT) (envelope-from benjamin@cactus.org) Received: (qmail 8263 invoked by uid 2051); 24 May 2006 23:38:47 -0000 From: benjamin@cactus.org Date: Wed, 24 May 2006 18:38:46 -0500 To: freebsd-net@freebsd.org Message-ID: <20060524233846.GA8189@linux.cactus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.5.1+cvs20040105i Subject: Blocking N consecutive packets with netgraph X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 24 May 2006 23:38:48 -0000 I need to test a multicast streaming media application by selectively dropping packets in the network connecting the source to the viewer. The capability I need is to drop N consecutive packets, where N ranges from 1 to 50 and is chosen via the command line. I had hoped to do this with dummynet and ipfw, but apparently I can only drop packets with a specified probablity. The network topology for this method was to bridge two ethernet nics, then use dummynet pipes to vary the bandwith and packet loss rate. I also tested a method using ipfw to temporarily enable packet block rules using a short sleep interval, but there was only very coarse control of the number of packets blocked. Is it feasible to do this with netgraph? Please outline how this may be accomplihsed. TIA Tom Benjamin