Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Michele Petrazzo - Unipex <michele.petrazzo@unipex.it>
To: J Webster <jw.jwebster@googlemail.com>
Cc: netfilter@vger.kernel.org
Subject: Re: limit bandwidth equally
Date: Thu, 11 Nov 2010 19:42:23 +0100	[thread overview]
Message-ID: <4CDC390F.6060508@unipex.it> (raw)
In-Reply-To: <4CDBDC82.6020006@googlemail.com>

J Webster ha scritto:
> I am using the following script for tc/htb.
> My server has 2 VPN services and a proxy server.
> The proxy server already limits using delay pools but I need to add a
> 1Mbps limit for every IP connecting to the VPN.
> The VPN is on tun1 and tun 0.
> Does the tc script go in the same folder as iptables.../etc/sysconfig?
>

No, it's not need.
This script are a separate "program".

> # The network interface we're planning on limiting bandwidth.
> IF=eth0 # Interface
> # Download limit (in mega bits)
> DNLD=1mbit # DOWNLOAD Limit
> # Upload limit (in mega bits)
> UPLD=1mbit # UPLOAD Limit

> $TC qdisc add dev $IF root handle 1: htb default 30
> $TC class add dev $IF parent 1: classid 1:1 htb rate $DNLD
> $TC class add dev $IF parent 1: classid 1:2 htb rate $UPLD

This is the first error that I found. With htb you cannot limit upload 
and download speed on the same interface. Are you looking for ifb?

Michele

      reply	other threads:[~2010-11-11 18:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-08 10:56 limit bandwidth equally J Webster
2010-11-09 10:47 ` Michele Petrazzo - Unipex
2010-11-11 12:07   ` J Webster
2010-11-11 18:42     ` Michele Petrazzo - Unipex [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4CDC390F.6060508@unipex.it \
    --to=michele.petrazzo@unipex.it \
    --cc=jw.jwebster@googlemail.com \
    --cc=netfilter@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox