Re: [LARTC] Broken filters?

2005-05-11 Thread Pan'ko Alexzender
On Wed, 11 May 2005 23:39:35 +0100
Andy Furniss <[EMAIL PROTECTED]> wrote:

> Pan'ko Alexzender wrote:
> > Hi!
> > By iptables I set marking (-j MARK) just before -j IMQ.
> > There are only three marks. Exectly all of them are ditected to 1:20
> 
> What are the rules.

There was three tables. At the end of each placed such rules:

iptables -t mangle -A IMQ_MARK1 -j MARK --set-mark 106
iptables -t mangle -A IMQ_MARK1 -j IMQ --todev 0

iptables -t mangle -A IMQ_MARK2 -j MARK --set-mark 107
iptables -t mangle -A IMQ_MARK2 -j IMQ --todev 0

iptables -t mangle -A IMQ_MARK2 -j MARK --set-mark 108
iptables -t mangle -A IMQ_MARK2 -j IMQ --todev 0
> 
> > 
> > Why I see 3 pkts in default 1:30? 
> > How explain it?
> 
> Maybe there was traffic flowing when you ran the script.

No. Than it rizes.


I recive too answears from:

gypsy <[EMAIL PROTECTED]>
"Most likeley the packets in 1:30 are not TCP.  They are probably UDP or
ARP or ICMP."

Marcin Ka_u_a <[EMAIL PROTECTED]>
"These are ARP packets. See Andy's reply to my question from 03 May in the 
archives"

I think they are right. But now I have mach more bigger problems, that makes me 
forgot this :).



I think it is problems of new kernel 2.6.11. There are configuration that makes 
karnel panic.
And IMQ not realy shapting (rate is not limited realy)... Now I testing this 
all...

Now I am wating for kernel pathes and trying lastest normal and test relises.


-- 
With best regards, Pan'ko Alexzender.
[EMAIL PROTECTED]
___
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc


Re: [LARTC] help regarding display with tc

2005-05-06 Thread Pan&#x27;ko Alexzender
On Fri, 6 May 2005 09:43:59 +0530
Supratim Mitra <[EMAIL PROTECTED]> wrote:

> hello,
> i'm a newbie to this field and a new member to this group.i hv gone
> through few tc howto and and succesfully controlled the bandwidth of a
> small network setup.
>  i have a query that is it possible to display the same.i.e. the
> number of packets uploaded or the number of packets dropped or limited
> due to BW control,etc. using tc commands.if so then what are those? or
> is it that i need some seperate script or tool for display.

I think that more surely and convenient do this by iptables rules. I use 
iptables.

If you need count dropped and limited pkts then 
tc -s class show dev ppp0
tc -s qdisc

Then bash, grep, awk ...

-- 
With best regards, Pan'ko Alexzender.
[EMAIL PROTECTED]
___
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc


[LARTC] Broken filters?

2005-05-05 Thread Pan&#x27;ko Alexzender

Hi!
By iptables I set marking (-j MARK) just before -j IMQ.
There are only three marks. Exectly all of them are ditected to 1:20

Why I see 3 pkts in default 1:30? 
How explain it?


### imq0: queueing disciplines

qdisc htb 1: r2q 10 default 30 direct_packets_stat 0
 Sent 631429 bytes 1812 pkts (dropped 0, overlimits 20)

### imq0: traffic classes

class htb 1:20 root prio 0 rate 100Kbit ceil 100Kbit burst 15Kb cburst 1727b
 Sent 630596 bytes 1809 pkts (dropped 0, overlimits 0)
 rate 3921bps 10pps
 lended: 1809 borrowed: 0 giants: 0
 tokens: 1121920 ctokens: 31360

class htb 1:30 root prio 7 rate 10Kbit ceil 80Kbit burst 1611b cburst 1701b
 Sent 833 bytes 3 pkts (dropped 0, overlimits 0)
 rate 2bps
 lended: 3 borrowed: 0 giants: 0
 tokens: 1244800 ctokens: 164600


### imq0: filtering rules

filter parent 1: protocol ip pref 100 fw
filter parent 1: protocol ip pref 100 fw handle 0x6a classid 1:20
filter parent 1: protocol ip pref 100 fw handle 0x6b classid 1:20
filter parent 1: protocol ip pref 100 fw handle 0x6c classid 1:20

Thanks for the attantion.

-- 
With best regards, Pan'ko Alexzender.
[EMAIL PROTECTED]
___
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc


Re: [OBORONA-SPAM] [LARTC] ppp+vpn+htb

2005-04-06 Thread Pan&#x27;ko Alexzender
On Wed, 6 Apr 2005 00:44:55 +0200
"mail.cat-net.co.yu" <[EMAIL PROTECTED]> wrote:

> please, help, i have build vpn server (suse 9 + poptop), i have managed to 
> implement tc htb in ip-up script, but every client has own ppp interface 
> (ppp0, ppp1, ppp2...), and my idea is to share available bandwidth, not to 
> limit connection, 
> 
> how to build root tc rule, when I have more then one interface?... please any 
> one width experiance
> 
> regards

Few month ago I have such trable too. Now I subscribed to this mail list in 
hope to resolve problem :).
My workaround done in a following way:
1.Difference is that I use pptpd.
2.The idea is to drive all traffic to unlim on a dev eth0, except "gre 1723". 
The traffic I wish to control I classify as default!
3.The rules a here:

/sbin/tc qdisc del dev eth0 root
/sbin/tc qdisc add dev eth0 root handle 1 htb default 30 r2q 100

/sbin/tc class add dev eth0 parent 1: classid 1:2 htb rate 100Mbit burst 15K

/sbin/tc class add dev eth0 parent 1:2 classid 1:10 htb rate 50Mbit burst 5K 
prio 5
/sbin/tc qdisc add dev eth0 parent 1:10 handle 10 sfq perturb 10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dport 
80 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dport 
110 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip sport 
110 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dport 
25 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dport 
139 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip sport 
139 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dport 
137 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip sport 
137 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dport 
138 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip sport 
138 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dport 
445 0x classid 1:10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip sport 
445 0x classid 1:10

/sbin/tc class add dev eth0 parent 1:2 classid 1:30 htb rate 200Kbit ceil 
200Kbit prio 5
/sbin/tc qdisc add dev eth0 parent 1:30 handle 30 sfq perturb 10

/sbin/tc class add dev eth0 parent 1:30 classid 1:1010 htb rate 10Kbit ceil 
80Kbit prio 5
/sbin/tc qdisc add dev eth0 parent 1:1010 handle 1010 sfq perturb 10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dst 
192.168.19.10 classid 1:1010

/sbin/tc class add dev eth0 parent 1:30 classid 1:1011 htb rate 10Kbit ceil 
80Kbit prio 5
/sbin/tc qdisc add dev eth0 parent 1:1011 handle 1011 sfq perturb 10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dst 
192.168.19.11 classid 1:1011

/sbin/tc class add dev eth0 parent 1:30 classid 1:1012 htb rate 10Kbit ceil 
80Kbit prio 5
/sbin/tc qdisc add dev eth0 parent 1:1012 handle 1012 sfq perturb 10
/sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 100 u32 match ip dst 
192.168.19.12 classid 1:1012
And so on.

This rules were compiled with help of shapecfg-2.2.12-15asp. Command - htb.

But all of this is wrong, only workaround.
Month of searching of ability to bridge (brctl), eql, teql etc. - bring nothing.
What I have to do :) - C, sources and compiler. I made little change to eql.c 
making this module only transparent transit device.
It's working... But I have some bugs, and now need help and testing. 

As I understood - qdisc and class can not apply to more then one device... Is 
it wrong?

Be free for asking more and feeding back.
And I am sorry if I have many mistakes in my English.

-- 
With best regards, Pan'ko Alexzender.
[EMAIL PROTECTED]
___
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc


Re: [OBORONA-SPAM] [LARTC] RTNETLINK answers: Invalid argument

2005-04-03 Thread Pan&#x27;ko Alexzender
On Sun, 03 Apr 2005 18:54:15 +0200
Nicolas Mailhot <[EMAIL PROTECTED]> wrote:

> Hi,
> 
> On this Fedora Core Devel (Raw Hide) system, if I boot on a distribution
> kernel (based on 2.6.12rc1-bk2) the network is fine. If I build a custom
> 2.6.12-rc1-V0.7.43-06 or 2.6.12-rc1-mm4 kernel the network interface
> fails to initialise on boot with RTNETLINK answers: Invalid argument.
> 
> What can possibly cause this ?

I advice you to rebuild iproute to.

-- 
With best regards, Pan'ko Alexzender.


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