Install HTB-Tools

Install HTB-Tools
=================

bwm:/# aptitude install shaper
bwm:/tmp# tar zxvf HTB-tools-0.3.0a-i486-1.tgz
bwm:/# mv /tmp/etc/* /etc/
bwm:/# mv /tmp/sbin/* /sbin/
bwm:/# mv /tmp/usr/* /usr/
bwm:/# cp /etc/rc.d/rc.htb.new /etc/init.d/rc.htb
bwm:/# chmod 755 /etc/init.d/rc.htb

Konfigurasi HTB-Tools
=====================


Asumsi :
Bandwidth Total = 2048 kbps
Jumlah Klient = 4 klient
eth0 = upstream
eth1 = downstream

bwm:/# cp /etc/htb/eth0-qos.cfg.new /etc/htb/eth0-qos.cfg
bwm:/# cp /etc/htb/eth1-qos.cfg.new /etc/htb/eth1-qos.cfg

bwm:/# vim /etc/htb/eth0-qos.cfg

isikan dari eth0-qos.cfg

#####################
# eth0-qos.cfg #
#-------------------#
# aagink@gmail.com #
#####################

class class_1 {
bandwidth 2048;
limit 2048;
burst 2;
priority 1;


client PC_1 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
src {
192.168.0.10/32;
};
};

client PC_2 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
src {
192.168.0.20/32;
};
};

client PC_3 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
src {
192.168.0.30/32;
};
};

client PC_4 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
src {
192.168.0.40/32;
};
};
};


class default { bandwidth 8; };


bwm:/# vim /etc/htb/eth1-qos.cfg

isikan dari eth1-qos.cfg

#######################
# eth1-qos.cfg #
#---------------------#
# aagink@gmail.com #
#######################

class class_1 {
bandwidth 2048;
limit 2048;
burst 2;
priority 1;


client PC_1 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
dst {
192.168.0.10/32;
};
};

client PC_2 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
dst {
192.168.0.20/32;
};
};

client PC_3 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
dst {
192.168.0.30/32;
};
};

client PC_4 {
bandwidth 512;
limit 512;
burst 2;
priority 1;
dst {
192.168.0.40/32;
};
};
};


class default { bandwidth 8; };

Cek Konfigurasi
===============

bwm:/# q_checkcfg /etc/htb/eth0-qos.cfg
Default bandwidth: 8

Class class_1, CIR: 2048, MIR: 2048
** 4 clients, CIR2: 2048, MIR2: 2048

1 classes; CIR / MIR = 2048 / 2048; CIR2 / MIR2 = 2048 / 2048

bwm:/# q_checkcfg /etc/htb/eth1-qos.cfg
Default bandwidth: 8

Class class_1, CIR: 2048, MIR: 2048
** 4 clients, CIR2: 2048, MIR2: 2048

1 classes; CIR / MIR = 2048 / 2048; CIR2 / MIR2 = 2048 / 2048


Aktifkan Shaper
===============

bwm:/# /etc/init.d/rc.htb start

Starting HTB-tools on eth0 ...
Checking the config file ...OK
Checking kernel support for HTB: present.
HTB-tools was successfuly started on eth0.


Starting HTB-tools on eth1 ...
Checking the config file ...OK
Checking kernel support for HTB: present.
HTB-tools was successfuly started on eth1.

Liat Trafik
===========

bwm:/# /etc/init.d/rc.htb show_eth0
bwm:/# /etc/init.d/rc.htb show_eth1

Comments :

0 comments to “Install HTB-Tools”

Komentar Anda...

 

Web Stat

Linux Today News Service

My Yahoo Messenger Status

Web Stat