* [LARTC] question about "rate"
@ 2000-10-27 17:58 Andreas
2000-10-27 20:54 ` Ing.Rodrigo
2000-10-28 12:55 ` bert
0 siblings, 2 replies; 3+ messages in thread
From: Andreas @ 2000-10-27 17:58 UTC (permalink / raw)
To: lartc
<PRE>Hi!
I am using DSL with 786Kbit downstream and 128Kbit upstream. When
someone fetches a file from my ftp server, my upstream is completely
blocked and download speeds from the internet of internal clients behind
the router slow down from ~90KB/s to 20-30KB/s. So I decided to limit
upstream bandwidth for access to the ftp-data port. Now I have two
questions:
1.) As you can see below, I allowed 56Kbit for ftp-data transfers. This
results in about 12KB/s. When I enter 64Kbit, full speed is consumed. Am
I doing something wrong here? I thought 96Kbit should result in 12K/s
and 128Kbit were full speed.
2.) How can I allow ftp-data transfers to get files at 128KBit speed,
when there is no other traffic on the line? I want to have ftp transfers
at a sufficient low priority, so that upstream and downstream from and
to internal hosts are not affected by my ftp-servers traffic.
This is the script I wrote:
--------------------------------------->
ALLOT="1492"
AVPKT="1000"
DEV="ppp0"
MAXBURST="20"
MAXRATE="128Kbit"
PERTURB="15"
tc qdisc del dev ${DEV} root handle 10:
tc qdisc add dev ${DEV} root handle 10: cbq bandwidth ${MAXRATE} avpkt
${AVPKT}
tc class add dev ${DEV} parent 10:0 classid 10:1 cbq bandwidth
${MAXRATE} \
rate ${MAXRATE} allot ${ALLOT} prio 8 maxburst ${MAXBURST} avpkt
${AVPKT}
tc class add dev ${DEV} parent 10:1 classid 10:200 cbq bandwidth
${MAXRATE} \
rate 56Kbit allot ${ALLOT} prio 5 maxburst ${MAXBURST} avpkt
${AVPKT} \
bounded
tc qdisc add dev ${DEV} parent 10:200 sfq quantum ${ALLOT}b perturb
${PERTURB}
tc filter add dev ${DEV} parent 10:0 protocol ip prio 25 \
u32 match ip sport 20 0xFFFF flowid 10:200
<---------------------------------------
Thanks in advance,
Andreas
</PRE>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [LARTC] question about "rate"
2000-10-27 17:58 [LARTC] question about "rate" Andreas
@ 2000-10-27 20:54 ` Ing.Rodrigo
2000-10-28 12:55 ` bert
1 sibling, 0 replies; 3+ messages in thread
From: Ing.Rodrigo @ 2000-10-27 20:54 UTC (permalink / raw)
To: lartc
<PRE>Hello,
><i> 1.) As you can see below, I allowed 56Kbit for ftp-data transfers. This
</I>><i> results in about 12KB/s. When I enter 64Kbit, full speed is consumed. Am
</I>><i> I doing something wrong here? I thought 96Kbit should result in 12K/s
</I>><i> and 128Kbit were full speed.
</I>
Hmm... same setup seems to work for me quite fine at 64Kbps, 65607 bits in
one second.
><i>
</I>><i> 2.) How can I allow ftp-data transfers to get files at 128KBit speed,
</I>><i> when there is no other traffic on the line? I want to have ftp transfers
</I>><i> at a sufficient low priority, so that upstream and downstream from and
</I>><i> to internal hosts are not affected by my ftp-servers traffic.
</I>
Removing the "bounded" on your class 10:200 will allow the class to borrow
bandwidth from other classes when they aren't using it. This is addressed
on the bandwidth limiting example, under "What to do with excess
bandwidth".
By the way, how can I stop Netscape from opening a second port on the ftp
server instead of using port 20 for data transfer? Testing with ftp
downloads under netscape results un full bandwidth as this connection is
used for data instead of source port 20:
(output from netstat -na)
tcp 0 0 192.168.144.99:44212 192.168.144.99:1064 ESTABLISHED
Cheers,
Rodrigo Goya
</PRE>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [LARTC] question about "rate"
2000-10-27 17:58 [LARTC] question about "rate" Andreas
2000-10-27 20:54 ` Ing.Rodrigo
@ 2000-10-28 12:55 ` bert
1 sibling, 0 replies; 3+ messages in thread
From: bert @ 2000-10-28 12:55 UTC (permalink / raw)
To: lartc
<PRE>On Fri, Oct 27, 2000 at 07:58:48PM +0200, Andreas Oberritter wrote:
><i> This is the script I wrote:
</I>><i> --------------------------------------->
</I>><i> ALLOT="1492"
</I>><i> AVPKT="1000"
</I>><i> DEV="ppp0"
</I>><i> MAXBURST="20"
</I>><i> MAXRATE="128Kbit"
</I>><i> PERTURB="15"
</I>><i>
</I>><i> tc qdisc del dev ${DEV} root handle 10:
</I>><i> tc qdisc add dev ${DEV} root handle 10: cbq bandwidth ${MAXRATE} avpkt
</I>><i> ${AVPKT
</I>
Can you specify the 'weight' of your connection as well, one tenth of
128kbit would seem in order.
Regards,
bert hubert
--
PowerDNS Versatile DNS Services
Trilab The Technology People
'SYN! .. SYN|ACK! .. ACK!' - the mating call of the internet
</PRE>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2000-10-28 12:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-10-27 17:58 [LARTC] question about "rate" Andreas
2000-10-27 20:54 ` Ing.Rodrigo
2000-10-28 12:55 ` bert
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.