Re: iptables performance and alternatives

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thursday 2008-05-15 13:04, Anton wrote:
>>
>> If you plan to use mark for QOS or routing why not simply
>> use native classifier of tc or "ip rule" ?
>
>Jan meant the exact case, I'm using this for shaper, so I 
>would need to remake scripts to use IPMARK... hopefully it 
>can also match networks... but this will give inflexibility 
>in many cases, like ports

IPMARK is a target so it itself does not deal with matching;
but if you meant marking network, well than nothing easier than that:
(pick one)

(a) -j IPMARK --and-mask 0xffffff00  (for a /24)
(b) -j IPMARK; -j MARK --and-mark 0xffffff00;

Now since you are concerned about speed I guess the former is what you want.
Perhaps varying (a) to not leave the 8 null bits:

(c) -j IPMARK --shift 8
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux