The script is corect ?
#!/bin/bash
/sbin/iptables -F -t mangle
/sbin/iptables -X
/sbin/iptables -t mangle -N mark_horiz_src
/sbin/iptables -t mangle -N mark_horiz_dst
/sbin/iptables -t mangle -A PREROUTING -i eth0 -j mark_horiz_src
/sbin/iptables -t mangle -A PREROUTING -i eth1 -j mark_horiz_dst
/sbin/iptables -t mangle -A OUTPUT -o eth0 -j mark_horiz_dst
/usr/local/bin/mipclasses -s mark_horiz_src -d mark_horiz_dst -m 1 < /start/metro.txt | iptables-restore -n
IF="eth0"
RATE_INET="256kbit"
RATE_METRO="1024kbit"
CEIL="512kbit"
#traficul implicit se duce in clasa 1:20 (internet)
tc qdisc add dev $IF root handle 1:0 htb default 20
tc class add dev $IF parent 1:0 classid 1:1 htb rate 240kbit
# clasa 1:10 pt traficul metropolitan
# clasa 1:20 pt traficul extern
# poti sa renunti la prio daca nu vrei prioritati diferite
tc class add dev $IF parent 1:1 classid 1:10 htb rate $RATE_METRO ceil $CEIL prio 2
tc class add dev $IF parent 1:1 classid 1:20 htb rate $RATE_INET ceil $CEIL prio 1
# setam disciplinele pentru fiecare clasa
# poti sa folosesti 'pfifo_fast' (disciplina implicita)
# in loc de 'sfq perturb 10'
tc qdisc add dev $IF parent 1:10 handle 10:0 sfq perturb 10
tc qdisc add dev $IF parent 1:20 handle 20:0 sfq perturb 10
# clasificam
pachetele dupa FW_MARK: 0x1=metropolitan -> 1:10
tc filter add dev $IF protocol ip parent 1:0 prio 1 handle 1 fw flowid 1:10
Tks !
Yahoo! FareChase - Search multiple travel sites in one click.
_______________________________________________ LARTC mailing list LARTC@xxxxxxxxxxxxxxx http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc