All of lore.kernel.org
 help / color / mirror / Atom feed
* [LARTC] Errors with GRED after upgrading to 2.6.18 kernel
@ 2006-10-18 17:04 Flechsenhaar, Jon J
  2006-11-11 13:10 ` Andy Furniss
  2006-11-11 13:53 ` Patrick McHardy
  0 siblings, 2 replies; 3+ messages in thread
From: Flechsenhaar, Jon J @ 2006-10-18 17:04 UTC (permalink / raw)
  To: lartc

[-- Attachment #1: Type: text/plain, Size: 2847 bytes --]

ALL:


 <<diffserv-gred_10-06>> 

I have attached the current script that I am using.  

$TC qdisc add dev $EDEV parent 2:20 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:20 gred DP 1 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.02 prio 2
$TC qdisc change dev $EDEV parent 2:20 gred DP 2 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.04 prio 3
$TC qdisc change dev $EDEV parent 2:20 gred DP 3 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.06 prio 4
### GRED for AF2

$TC qdisc add dev $EDEV parent 2:30 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:30 gred DP 1 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.02 prio 2
$TC qdisc change dev $EDEV parent 2:30 gred DP 2 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.04 prio 3
$TC qdisc change dev $EDEV parent 2:30 gred DP 3 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.06 prio 4
### GRED for AF3

$TC qdisc add dev $EDEV parent 2:40 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:40 gred DP 1 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.02 prio 2
$TC qdisc change dev $EDEV parent 2:40 gred DP 2 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.04 prio 3
$TC qdisc change dev $EDEV parent 2:40 gred DP 3 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.06 prio 4
### GRED for AF4

$TC qdisc add dev $EDEV parent 2:50 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:50 gred DP 1 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.02 prio 2
$TC qdisc change dev $EDEV parent 2:50 gred DP 2 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.04 prio 3
$TC qdisc change dev $EDEV parent 2:50 gred DP 3 limit $lim min $minTh
max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability
0.06 prio 4

Each DP3 line gives me an error.  If I comment it out the error goes
away.  The line translates to below.  

I get an error with the following line
++ /usr/sbin/tc qdisc change dev eth0 parent 2:20 gred DP 3 limit 60kb
min 10kb max 20kb avpkt 1500 burst 9 bandwidth 500kbit probability 0.06
prio 4 RTNETLINK answers: Invalid argument

after each DP 3 on each gred.

This starting happening after I upgraded to 2.6.18 from 2.4.20 kernel.
Anyone have any ideas?

Jon Flechsenhaar
Boeing WNW Team
Network Services
(714)-762-1231
202-E7


[-- Attachment #2: diffserv-gred_10-06 --]
[-- Type: application/octet-stream, Size: 8831 bytes --]

#/bin/sh
#
# TC Script for JTRS WNW QoS
# IP Precedence and Differentiated Services
#
# tc script
TC=/sbin/tc
#                                                                                                                                                            # Print usage
echo "usage: $0 [show | del]"
#                                                                                                                                                            
# Interface
EDEV=eth1       # Black IP
#EDEV=htun0      # Red IP
#                                                                                                                                                            
# Rates
#EF_RATE=100kbit
#AF1_RATE=150kbit
#AF2_RATE=120kbit
#AF3_RATE=60kbit
#MAX_RATE=700kbit
#MIN_RATE=1kbit
#TBF_RATE=150kbit
#
# Rates
EF_RATE=100kbit
AF1_RATE=160kbit
AF2_RATE=120kbit
AF3_RATE=70kbit
AF4_RATE=40kbit
BE_RATE=10kbit
MAX_RATE=550kbit
#CEIL_RATE=550
MIN_RATE=1kbit
TBF_RATE=525kbit
burst=1b
cburst=1b
pburst=1b
#
#
# GRED variable values
lim=60kb
maxTh=20kb
minTh=10kb
bursty=9
netBand=500kbit
avgPL=1500                                                                                                                                           
#
# Queue packet size for PFIFO
QSIZE=10
#                                                                                                                                                            
# Quantum value for HTB
QUANTUM=" quantum 1600"

#                                                                                                                                                            
if [ ! -x $TC ]; then
        echo "Cannot find $TC. No installed?"; exit 1; fi
#if [ $# -ne 2 ]; then
#       echo ">>Error: wrong usage. Aborting!"; echo; exit 1; fi
if [ "$1" = show ]; then
        echo "HTB settings at $EDEV:"
        $TC qdisc ls dev $EDEV
        $TC class ls dev $EDEV
        echo; exit 1; fi
if [ "$1" = del ]; then
        $TC qdisc del dev eth0 root
        $TC qdisc del dev eth1 root
        $TC qdisc del dev eth2 root
        $TC qdisc del dev eth3 root
        $TC qdisc del dev htun0 root
        echo " All queues have been deleted"; echo; exit 1; fi
echo "Interface = $EDEV"
#
### INITIALIZATION
#
### ROOT DSMARK
$TC qdisc add dev $EDEV handle 1:0 root dsmark indices 16 set_tc_index
$TC filter add dev $EDEV parent 1:0 protocol ip prio 1 tcindex mask 0xfc shift 2 pass_on
#
echo "DS";
### FILTER for EF and AF
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x2e tcindex classid 1:110
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x0a tcindex classid 1:121
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x0c tcindex classid 1:122
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x0e tcindex classid 1:123
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x12 tcindex classid 1:131
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x14 tcindex classid 1:132
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x16 tcindex classid 1:133
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x1a tcindex classid 1:141
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x1c tcindex classid 1:142
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x1e tcindex classid 1:143
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x22 tcindex classid 1:151
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x24 tcindex classid 1:152
$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x26 tcindex classid 1:153
#$TC filter add dev $EDEV parent 1: protocol ip prio 1 handle 0x00 tcindex classid 1:160
#$TC filter add dev $EDEV parent 1: protocol ip prio 2 u32 match ip tos 0x00 0xff flowid 2:60
#
#
### MAIN HTB
$TC qdisc add dev $EDEV parent 1: handle 2: htb default 60 #r2q 1
#
echo "Main htb";
#
### HTB rate limit
$TC class add dev $EDEV parent 2: classid 2:1 htb rate $MAX_RATE #burst $burst cburst $pburst
#
#
### DIFFERENTIATED SERVICES
#
#
### HTB
#
$TC filter add dev $EDEV parent 2: protocol ip prio 1 tcindex mask 0xf0 shift 4 pass_on
#
echo "EF and AF";
### CLASS for EF
$TC class add dev $EDEV parent 2:1 classid 2:10 htb rate $EF_RATE ceil $MAX_RATE prio 1 $QUANTUM #burst $burst cburst $cburst
$TC filter add dev $EDEV parent 2: protocol ip prio 1 handle 1 tcindex classid 2:10
$TC qdisc add dev $EDEV parent 2:10 handle 22: tbf rate $TBF_RATE burst 20kb mtu 1540 latency .01ms
#
### CLASSES for AF
$TC class add dev $EDEV parent 2:1 classid 2:20 htb rate $AF1_RATE ceil $MAX_RATE prio 2 $QUANTUM #burst $burst cburst $cburst
$TC class add dev $EDEV parent 2:1 classid 2:30 htb rate $AF2_RATE ceil $MAX_RATE prio 3 $QUANTUM #burst $burst cburst $cburst
$TC class add dev $EDEV parent 2:1 classid 2:40 htb rate $AF3_RATE ceil $MAX_RATE prio 4 $QUANTUM #burst $burst cburst $cburst
$TC class add dev $EDEV parent 2:1 classid 2:50 htb rate $AF4_RATE ceil $MAX_RATE prio 5 $QUANTUM #burst $burst cburst $cburst
#
$TC filter add dev $EDEV parent 2: protocol ip prio 1 handle 2 tcindex classid 2:20
$TC filter add dev $EDEV parent 2: protocol ip prio 1 handle 3 tcindex classid 2:30
$TC filter add dev $EDEV parent 2: protocol ip prio 1 handle 4 tcindex classid 2:40
$TC filter add dev $EDEV parent 2: protocol ip prio 1 handle 5 tcindex classid 2:50
echo "af classes done";
#
#
echo "GRED";
$TC qdisc add dev $EDEV parent 2:20 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:20 gred DP 1 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.02 prio 2
$TC qdisc change dev $EDEV parent 2:20 gred DP 2 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.04 prio 3
$TC qdisc change dev $EDEV parent 2:20 gred DP 3 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.06 prio 4
### GRED for AF2
$TC qdisc add dev $EDEV parent 2:30 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:30 gred DP 1 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.02 prio 2
$TC qdisc change dev $EDEV parent 2:30 gred DP 2 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.04 prio 3
$TC qdisc change dev $EDEV parent 2:30 gred DP 3 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.06 prio 4
### GRED for AF3
$TC qdisc add dev $EDEV parent 2:40 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:40 gred DP 1 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.02 prio 2
$TC qdisc change dev $EDEV parent 2:40 gred DP 2 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.04 prio 3
$TC qdisc change dev $EDEV parent 2:40 gred DP 3 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.06 prio 4
### GRED for AF4
$TC qdisc add dev $EDEV parent 2:50 gred setup DPs 3 default 2 grio
$TC qdisc change dev $EDEV parent 2:50 gred DP 1 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.02 prio 2
$TC qdisc change dev $EDEV parent 2:50 gred DP 2 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.04 prio 3
$TC qdisc change dev $EDEV parent 2:50 gred DP 3 limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.06 prio 4
#
echo "BE";
### CLASS for Best Effort and Default
$TC class add dev $EDEV parent 2:1 classid 2:60 htb rate $BE_RATE ceil $MAX_RATE prio 6 $QUANTUM #burst $burst cburst $cburst
#$TC filter add dev $EDEV parent 2: protocol ip u32 match ip src 0.0.0.0/0 flowid 2:60
#$TC filter add dev $EDEV parent 2: protocol ip prio 2 handle 6 tcindex classid 2:60
##$TC qdisc add dev $EDEV parent 21:5 handle 26: pfifo limit $QSIZE
$TC qdisc add dev $EDEV parent 2:60 red limit $lim min $minTh max $maxTh avpkt $avgPL burst $bursty bandwidth $netBand probability 0.6
###
#
#
#
echo "comments";
###NOT USING NOW
## HTB classes - IP Precedence / DiffServ / Default Best Effort
#$TC class add dev $EDEV parent 1:1 classid 1:10 htb rate $MIN_RATE ceil $MAX_RATE prio 1 $QUANTUM
#$TC class add dev $EDEV parent 1:1 classid 1:20 htb rate $MIN_RATE ceil $MAX_RATE prio 3 $QUANTUM
#$TC class add dev $EDEV parent 1:1 classid 1:30 htb rate $MIN_RATE ceil $MAX_RATE prio 3 $QUANTUM
#
###                                                                                                          
### CLASSIFICATION FILTERS
#
### Differentiated Services (DiffServ) PHB
#$TC filter add dev $EDEV parent 1: protocol ip u32 match ip src 0.0.0.0/0 flowid 1:20
#
echo "end";

[-- Attachment #3: Type: text/plain, Size: 143 bytes --]

_______________________________________________
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-11-11 13:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-10-18 17:04 [LARTC] Errors with GRED after upgrading to 2.6.18 kernel Flechsenhaar, Jon J
2006-11-11 13:10 ` Andy Furniss
2006-11-11 13:53 ` Patrick McHardy

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.