Ubuntu / Linux news and application reviews.

Trickle is a Linux application which allows you to limit the network bandwidth of individual applications such as a torrent client, web browsers or any other program.

Trickle should be present in your distro repository so install it from there. In Ubuntu, just paste this in a terminal:
sudo apt-get install trickle

Speed is limited by controlling the amount of the data written or read from a socket. Trickle can only work on TCP connections, so you can't use it to regulate UDP stream connection such as DNS. Not only that, it can't work with all TCP connections either. Since Trickle uses the dynamic linking and loading, it can only work with applications that use dynamic libraries (Glibc). To test and see if an application can have it's upload and download speed controlled by Trickle, use this command (this is an example for Epiphany):
ldd /usr/bin/epiphany | grep libc.so

If that gives you an output, it means it does work!

When setting speeds, it can fluctuate by as much as 5kbps.

To set an upload or download speed for an application, use this command:
trickled -d 50 -u 10 <application>
where "-d 50" is the maximum download speed (50 K/s), "-u 50" is the maximum upload speed (50 K/s) and well "<application>" is the application command. To reset the up/down speed, simply close the terminal.

But Trickle can do more than just limit upload and download speeds for Linux. This nifty little tool lets you set per-application priority, and you can also define time and length-soothing parameters. Don't let the fancy jargon scare you. With time-smoothing, you can define the time interval for the application to transfer data. Large values will produce bursts in sending and receiving data while smaller values ensure a smooth and continuous data transfer. You need to use the -t command switch to define the time-smoothing values (in seconds). The default value is 5s.