From owner-freebsd-questions@FreeBSD.ORG Fri Oct 12 21:18:47 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2A7B616A419 for ; Fri, 12 Oct 2007 21:18:47 +0000 (UTC) (envelope-from ovi@unixservers.us) Received: from webserver.easyhosting.ro (unixware.iasi.rdsnet.ro [86.124.41.195]) by mx1.freebsd.org (Postfix) with ESMTP id DFB5613C49D for ; Fri, 12 Oct 2007 21:18:46 +0000 (UTC) (envelope-from ovi@unixservers.us) Received: from [10.0.0.14] (unknown [10.0.0.14]) (Authenticated sender: ovi@unixservers.us) by webserver.easyhosting.ro (Postfix) with ESMTP id 609BAFD01D for ; Sat, 13 Oct 2007 00:18:30 +0300 (EEST) Message-ID: <470FF27C.7050806@unixservers.us> Date: Sat, 13 Oct 2007 00:17:32 +0200 From: Ovi User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.2) Gecko/20040804 Netscape/7.2 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Free BSD Questions list Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: PF ALTQ CBQ rules X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Oct 2007 21:18:47 -0000 Hello guys I have this example from OpenBSD: altq on $br1_if cbq bandwidth 20Mb qlimit 100 tbrsize 1000 queue { std1, customer_1 } queue customer_1 bandwidth 1Mb cbq(red,ecn) { customer_1_bulk, customer_1_ack } queue customer_1_ack priority 7 queue customer_1_bulk priority 0 I want to use CBQ on FreeBSD, with similar rules still I have the following problem: On a 20Mb internet line I have 100 users. I want to limit (cap) bandwidth per user at 1 Mb and to add queues for all 100 users. The problem is that on FreeBSD this rules are not working, instead I must use this: altq on $br1_if cbq bandwidth 20Mb qlimit 100 tbrsize 1000 queue { std1, customer_1 } queue customer_1 bandwidth 1Mb cbq(red,ecn) { customer_1_bulk, customer_1_ack } queue customer_1_ack bandwidth 800Kb priority 7 queue customer_1_bulk bandwidth 128Kb priority 0 This "bandwidth" option does not help me because I must not exceed 1 Mb. My second problem is if I have 100 users, then toal of 1Mb x 100 will be 100Mb and I exceed total bandwidth of 20 Mb. So my question is: how I do bandwidthupper limit with CBQ per user, like no more than 1 Mb, and add rules for 100 users? best regards, ovi