Use Wondershaper to limit network bandwidth usage in Linux

Source: Internet
Author: User

Wondershaper is actually a shell script that usesTcto define traffic-tuning commands and use QoS to handle specific network interfaces. Outbound traffic is designed to limit the rate of outgoing traffic by placing it in a queue of different priorities, and incoming traffic is lost to the rate limit.

In fact, Wondershaper's set goal is not just to increase its bandwidth limit on an interface; when bulk download or upload is in progress, Wondershaper also tries to keep interactive sessions such as SSH low latency. Also, it controls bulk uploads (for example, Dropbox syncing) without "choking" the download and vice versa.

Install Wondershaper in Ubuntu Debian and its derived distributions:

sudo Install Wondershaper

Install Wondershaper in Fdora or Centos/rhel (with EPEL repositories):

sudo Yum Install Wondershaper

The basic use of Wondershaper is as follows:

sudo wondershaper <interface> <download-rate> <upload-rate>

For example, the eth0 maximum download/upload bandwidth is set to 1000KBIT/S and 500kbit/s, respectively:

sudo  the

You can also eliminate the rate limit by running the following command:

sudo Clear eth0

If you are interested in the operating principle of wondershaper, you can read its shell script source file (/sbin/wondershaper).

Ps:

Http://www.linuxidc.com/Linux/2015-03/115538.htm

Use Wondershaper to limit network bandwidth usage in Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.