All of lore.kernel.org
 help / color / mirror / Atom feed
From: "S Mohan" <smohan@vsnl.com>
To: lartc@vger.kernel.org
Subject: RE: [LARTC] very simple problem to help me understand
Date: Thu, 20 Mar 2003 04:27:30 +0000	[thread overview]
Message-ID: <marc-lartc-104813375915214@msgid-missing> (raw)
In-Reply-To: <marc-lartc-104808760000769@msgid-missing>

ASCII art below:


Internet ==== eth0-Linux-eth1=== LAN

Assuming ftp traffic is active thus ftp-data port is 20 and connection
port is 21. PASV uses high ports available and would be more cumbersome
to filter.

Incoming traffic on eth0 from the Internet is outgoing traffic on eth1
(Remember only outgoing traffic can be shaped). Shaping ftp traffic on
eth1 will be equivalent to shaping incoming traffic on eth0.

tc qdisc add dev eth1 root handle 1 htb default 20
tc class add dev eth1 parent 1: classid 1:10 htb rate 10kbit
tc class add dev eth1 parent 1: classid 1:20 htb rate 100kbit ceil
128kbit
#Match ftp and direct to class 1:10
tc filter add dev eth1 parent 1:0 protocol ip u32 match ip dport 21
classid 1:10
tc filter add dev eth1 parent 1:0 protocol ip u32 match ip dport 20
classid 1:10

This should get you started. Hook on to http://www.docum.org and you'll
get some good stuff.

Mohan
-----Original Message-----
From: lartc-admin@mailman.ds9a.nl [mailto:lartc-admin@mailman.ds9a.nl]
On Behalf Of Jeremy Hansen
Sent: Wednesday, March 19, 2003 8:56 PM
To: LARTC@mailman.ds9a.nl
Subject: [LARTC] very simple problem to help me understand



I want a small excersize to understand how everything fits together.
What 
I'd like to do is limit incoming ftp traffic to 10k/second.  That's all.

This should be enough to understadn how everything works.  Can someone 
help me with a quick recipe?

Thanks
-jeremy

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

      parent reply	other threads:[~2003-03-20  4:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-19 15:25 [LARTC] very simple problem to help me understand Jeremy Hansen
2003-03-19 15:39 ` John Cushnie
2003-03-19 15:40 ` Martin A. Brown
2003-03-20  4:27 ` S Mohan [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=marc-lartc-104813375915214@msgid-missing \
    --to=smohan@vsnl.com \
    --cc=lartc@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.