From owner-freebsd-pf@FreeBSD.ORG Wed Jul 23 15:54:52 2008 Return-Path: Delivered-To: freebsd-pf@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4AA101065676 for ; Wed, 23 Jul 2008 15:54:52 +0000 (UTC) (envelope-from buchtajz@borsice.net) Received: from mx.sitkom.cz (mx.sitkom.cz [88.146.187.34]) by mx1.freebsd.org (Postfix) with ESMTP id 1E1998FC1E for ; Wed, 23 Jul 2008 15:54:52 +0000 (UTC) (envelope-from buchtajz@borsice.net) Received: from [10.10.0.12] (manwe.buchtikov.borsice.sfn [10.10.0.12]) by mx.sitkom.cz (Postfix) with ESMTP id BC9CF1C4A10 for ; Wed, 23 Jul 2008 17:37:42 +0200 (CEST) From: Michal Buchtik Cc: freebsd-pf@freebsd.org In-Reply-To: <8dfae1c10807230603o1060aa69jc9ccf2e4bc66f275@mail.gmail.com> References: <8dfae1c10807230603o1060aa69jc9ccf2e4bc66f275@mail.gmail.com> Content-Type: text/plain; charset=UTF-8 Date: Wed, 23 Jul 2008 17:35:49 +0200 Message-Id: <1216827349.1598.4.camel@manwe.buchtikov.borsice.sfn> Mime-Version: 1.0 X-Mailer: Evolution 2.22.3.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 8bit Subject: Re: Limiting client bandwidth with PF X-BeenThere: freebsd-pf@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Technical discussion and general questions about packet filter \(pf\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jul 2008 15:54:52 -0000 Walter Venable píše v st 23. 07. 2008 v 16:03 +0300: > First things first, limit them to 128Kbps, but that isn't even working, as > clients are still maxing at 3Mbps: > > $ cat /etc/pf.conf > int_if="rl0" > ext_if="nfe0" > int_net="192.168.2.0/24" > > altq on $ext_if hfsc bandwidth 3Mb queue { clients } > queue clients bandwidth 128Kb hfsc ( default rio ) > pass in quick log on $int_if proto tcp from $int_net to any \ > flags S/SA keep state queue clients > You can limit only OUTGOING traffic (from router point of view). So change the line to: altq on $int_if hfsc bandwidth 3Mb queue { clients } Michal