This is a multi-part message in MIME format.
------=_NextPart_000_004D_01C2A6AD.462B6FC0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hi, All,
I did some work on QoS with CBQ. Basically, I wanted to separate VoIP =
traffic from other traffics and give it guarantied bandwidth. I used the =
following scripts to do the work,
#!/bin/sh
OPTION=3D"allot 1514 maxburst 20 avpkt 1000"
tc qdisc del dev eth0 root=20
tc qdisc add dev eth0 root handle 10: cbq bandwidth 10mbit avpkt 1000
tc class add dev eth0 parent 10: classid 10:2 cbq bandwidth 10mbit rate =
34kbit $OPTION prio 3 bounded
tc class add dev eth0 parent 10:2 classid 10:10 cbq bandwidth 10mbit =
rate 30kbit $OPTION prio 3=20
tc class add dev eth0 parent 10:2 classid 10:20 cbq bandwidth 10mbit =
rate 4kbit $OPTION prio3
tc filter add dev eth0 parent 10: protocol ip prio 3 u32 match ip tos =
0x20 0xf0 flowid 10:2
tc filter add dev eth0 parent 10: protocol ip prio 3 u32 match ip dst =
0/0 flowid 10:2
tc filter add dev eth0 parent 10:2 protocol ip prio 3 u32 match ip tos =
0x20 0xf0 flowid 10:10
tc filter add dev eth0 parent 10:2 protocol ip prio 3 u32 match ip dst =
0/0 flowid 10:20
It seemed working -- when there was no VoIP traffic, a ftp link was =
using all 34kbit rate. When there was VoIP traffic, the ftp rate dropped =
to 17kbit (which was correct because the voice traffic was using =
17kbit). Unfortunately, the voice quality was not good. Even if without =
ftp traffic, there were packets loss for voice traffic (if you count =
from 1 to 20 with one handset, you miss certain figures on the other =
end, they are 4, 5, 8, 9, 12, 13 etc).
Any one had the same problem before? Any one can explain it? Any =
parameter I should adjust to better suit this application?
Another thing I noticed was, when I changed the parameters for "allot"
=
(ex 300) and "avpkt" (ex 500) in order to seek better setting for this
=
application, the CBQ stopped doing anything, so the rate was the NIC =
rate instead of 34kbit. I could change "maxburst" but it didn't
improve =
the voice quality. Could any one tell me how to use these parameters?
Thanks,
James=20
------=_NextPart_000_004D_01C2A6AD.462B6FC0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2600.0" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Hi, All,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>I did some work on QoS with CBQ. =
Basically, I=20
wanted to separate VoIP traffic from other traffics and give it =
guarantied=20
bandwidth. I used the following scripts to do the work,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV>
<DIR>
<P>#!/bin/sh</P></DIR><FONT size=3D2>
<P></P>
<DIR></FONT>
<P>OPTION=3D"allot 1514 maxburst 20 avpkt
1000"<BR></P>
<P>tc qdisc del dev eth0 root <BR></P>
<P>tc qdisc add dev eth0 root handle 10: cbq bandwidth 10mbit avpkt =
1000</P>
<P>tc class add dev eth0 parent 10: classid 10:2 cbq bandwidth 10mbit =
rate=20
34kbit $OPTION prio 3 bounded</P>
<P>tc class add dev eth0 parent 10:2 classid 10:10 cbq bandwidth 10mbit =
rate=20
30kbit $OPTION prio 3 </P>
<P>tc class add dev eth0 parent 10:2 classid 10:20 cbq bandwidth 10mbit =
rate=20
4kbit $OPTION prio3<BR><BR>tc filter add dev eth0 parent 10:
protocol ip =
prio 3=20
u32 match ip tos 0x20 0xf0 flowid 10:2</P>
<P>tc filter add dev eth0 parent 10: protocol ip prio 3 u32 match ip dst =
0/0=20
flowid 10:2</P>
<P>tc filter add dev eth0 parent 10:2 protocol ip prio 3 u32 match ip =
tos 0x20=20
0xf0 flowid 10:10</P>
<P>tc filter add dev eth0 parent 10:2 protocol ip prio 3 u32 match ip =
dst 0/0=20
flowid 10:20</P>
<P><FONT face=3DArial
size=3D2></FONT><BR></P><FONT size=3D2><FONT =
face=3DArial>It=20
seemed working -- when there was no VoIP traffic, a ftp link was =
using all=20
34kbit rate. When there was VoIP traffic, the ftp rate dropped to =
17kbit=20
(which was correct because the voice traffic was using 17kbit). =
Unfortunately,=20
the voice quality was not good. Even if without ftp traffic, there were =
packets=20
loss for voice traffic (if you count from 1 to 20 with one handset, =
you=20
miss certain figures on the other end, they are 4, 5, 8, 9, 12, 13=20
etc).</FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT face=3DArial>Any one had the same
problem =
before? Any one=20
can explain it? Any parameter I should adjust to better suit this=20
application?</FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial></FONT></FONT></DIR>
<DIR><FONT size=3D2><FONT face=3DArial>Another thing I noticed
was, when =
I changed=20
the parameters for "allot" (ex 300) and "avpkt" (ex 500) in
order to=20
seek better setting for this application, the CBQ stopped =
doing=20
anything, so the rate was the NIC rate instead of =
34kbit. I could=20
change "maxburst" but it didn't improve the voice quality. Could any
one =
tell me=20
how to use these parameters?</FONT></FONT></DIR>
<DIR></DIR>
<DIR><FONT size=3D2><FONT
face=3DArial>Thanks,</FONT></FONT></DIR>
<DIR></DIR>
<DIR><FONT face=3DArial =
size=3D2>James</FONT> </DIR></DIV></BODY></HTML>
------=_NextPart_000_004D_01C2A6AD.462B6FC0--