Barra de espaço
Barra de espaço

This tutorial describes a detailed procedure showing how to perform traffic shaper on a computer running Ubuntu or Debian operating system

topologia shaper

YOUTUBE

In our channel you can view the video of this tutorial.



DATE & TIME 

Follow the steps shown in the video tutorial below to configure the correct date & time on your system

 

 

Install the required package.

 

# apt-get install iproute


Run the following command to clear any existing bandwidth limitation policy at the interface connected to the internal network (ETH2).

# tc qdisc del dev eth2 root

 

If the interface has not yet any bandwidth limitation policy set the error below will be displayed.

RTNETLINK answers: No such file or directory

 
Do not worry and go to the next step.

Execute the following commands to limit the computer with IP 192.168.3.220 to 50KBytes bandwidth.

# tc qdisc add dev eth2 root handle 1: cbq avpkt 1000 bandwidth 10mbit

# tc class add dev eth2 parent 1: classid 1:1 cbq rate 400kbit allot 1500 prio 5 bounded isolated

# tc filter add dev eth2 parent 1: protocol ip prio 16 u32 match ip dst 192.168.3.220 flowid 1:1

 

The first line adds the CBQ bandwidth shaper feature in ETH2 interface.

The second line creates a limited class with 400 Kbits which is equivalent to 50KBytes.

The third line associates the computer with IP 192.168.3.220 to the limited policy of 400Kbits.

To test, go to the computer with the IP 192.168.3.220 and test your bandwidth limit setting. (Download something)

CONCLUSION

This tutorial presented a bandwidth shaper configuration on a computer running Ubuntu.