Hi Stefan,

It's way more complex than that. I just published a PR for a new package
that does traffic shaping:

https://github.com/openwrt/packages/pull/5926

You can give a feedback at github.

If you are not familiar with building a package, just copy
/etc/init.d/trafficshaper, /etc/config/trafficshaper
and /etc/hotplug.d/iface/11-trafficshaper to your router.

Regards,

Em seg, 16 de abr de 2018 às 14:40, Stefan Monnier <monn...@iro.umontreal.ca>
escreveu:

> I'm trying to limit bandwidth usage of a particular set of hosts.
>
> After reading various manpages and webpages about tc, qdisc, classes and
> whatnot, I believe I mostly know what I'd like to do and how, but the
> final details still elude me:
>
> Basically, I want to pass traffic destined to a particular set of local
> hosts (say 192.168.1.16/29) through the `tbf` traffic shaping scheduler.
>
> Now if these hosts were connected to their own network interfaces,
> I believe I could just do something like
>
>     tc qdisc add dev $IF root tbf burst 1mb rate 100kbps
>
> but since these are connected to the same network interface as several
> other machines (for which I do not want to do any particular traffic
> shaping), I have to do it differently:
>
>     iptables -t mangle -A POSTROUTING -j CLASSIFY \
>              --dst 192.168.1.16/29 --set-class 1:10
>
> supposedly sets a "class 1:10" on each package destined to one of those
> hosts, and I "just" need to setup my $IF such that packets of this class
> go through the tbf scheduler.
>
> But that's where I'm stumped, because `tbf` is a classless scheduler, so
> I need to set a classful scheduler on $IF which divides the traffic
> between 2 classes one of which goes through the tbf scheduler.
> And I haven't been able to figure out how to do that.  Any help?
>
>
>         Stefan
> _______________________________________________
> openwrt-users mailing list
> openwrt-users@lists.openwrt.org
> https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-users
>
-- 

Luiz Angelo Daros de Luca
luizl...@gmail.com
_______________________________________________
openwrt-users mailing list
openwrt-users@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-users

Reply via email to