LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   htb.init (https://www.linuxquestions.org/questions/slackware-14/htb-init-163682/)

Ipolit 03-29-2004 05:34 AM

htb.init
 
I have a little router with Slack 9.0 which operates with a small network with 4 computers.
I decided to start htb.init to share the traffic fairily. In the htb.init it's written that I should use sfq and nothing more. The idea is all the computers in the network to recieve equal traffic.
So I recompiled the kernel with htb, QoS, and all needed.
I put htb.init in /var/cache
I made a file eth0 in /etc/sysconfig/htb
LEAF=sfq
RULE=192.168.0.0/24
R2Q=1

after this I made
htb.init compile
htb.init start nocache
when I make lsmod I receive:
sch_sfq 3360 0 (unused)
sch_htb 19392 1
Do you think that my htb.init makes something? I'm not shore.
Do you have any suggestions what should I do?
Thanks

frostschutz 05-01-2004 02:30 PM

I don't think that HTB.init can do anything useful with that kind of configuration. It should at least know the IPs of your machines, otherwise it'd have to create a whole load of classes to cover the complete subnet. Or is the class structure by chance dynamically reconfigured when clients connect? That would be nifty, but the script doesn't look anything like it at the first glance.

I had a similar problem (5 machines behind a stand-alone router). The scripts I found on the net either looked much too complicated to modify (like HTB.init) or just didn't quite do what I wanted. So I wrote my own script after reading lots of stuff on www.lartc.org and other sites. Maybe you have to do that too... Everyone has other thoughts about what traffic shaping should look like,, so there is no general script that solves everything in every case.

There are two scripts you may want to look at. One is the Wondershaper on www.lartc.org, the other is my own script. It could be useful since it's in general the same idea, a router with machines behind it and traffic that should be shared fairly among them. My script won't do you any good however if you aren't able to do certain modifications to it. The design is simple, but rather static.

My script can be found here: http://www.metamorpher.de/files/ipshape.sh

For four users, you'd have to remove all lines that contain $USER_E and modify the mathematics (so that rates aren't divided by 5 anymore, but by 4 instead... feh, I should put them mathematics in variables, too... bug me about it and I'll do just that)

frostschutz 05-02-2004 01:23 PM

Quote:

For four users, you'd have to remove all lines that contain $USER_E and modify the mathematics (so that rates aren't divided by 5 anymore, but by 4 instead... feh, I should put them mathematics in variables, too... bug me about it and I'll do just that)
I just made the script a little more flexible. It now supports a variable number of users behind the router. All you have to do is specify their IPs. Here's a little documentation: http://www.metamorpher.de/ipshape/.

If this doesn't fit you, use HTB.init. I just read a little more about HTB.init - as far as I understand it, it doesn't do anything by default. It's just a script that provides an easier method to configure HTB classes and filters. So you have to figure out by yourself what kind of class structure you might want.


All times are GMT -5. The time now is 07:18 PM.