How do I reserve bandwidth?

In windows there is a registry entry called Reserve bandwidth. With that system was reserved some bandwidth from my INTERNET connection so that when i am downloading all other connected application can run with minimum INTERNET support.

Like reserve bandwidth help to keep other application (all kind of messenger) on-line when i was downloading. But in Ubuntu my connection speed is good enough but problem arise when i am downloading a file, all my messenger gets off-line status. Can any one tell how can i fix such problem? Or why this is happening?


Solution 1:

(Credit goes to the answerer of this post in Super User)

  • Install trickle with this command:

    sudo apt-get install trickle
    

    Or using Software Center:

    Install via the software center

  • Start any program with trickle specifying it's download limits. For example, opening a new Firefox instance with 20 KB/s download limit, use this command

    trickle -s -d 20 firefox
    

    Here, -s saying trickle is running in standalone without any daemon, -d is doing the limit on download speed. You can also use -u option to specify an upload speed.

See the trickle manual page for more help.


If you want to limit the bandwidth of the interface card

There is also another tool which can be used to limit the speed of a Network interface. It's called wondershaper. With this tool you can limit the speed of the interface card.

  • Install it with this command:

    sudo apt-get install wondershaper
    

    Or using Software Center:

    Install via the software center

  • To limit the download speed of eth1 interface to 2000 Kilobit/sec, I'd run this command:

    wondershaper eth1 2000

    The exact syntax is

    wondershaper [ interface ] [ downlink ] [ uplink ]

Manual page for wondershaper