0

How to limit the connection (upload and download) speed of a particular application (e.g., a particular exe file) in accessing the internet?

Apparently, it is easy to allow or block completely using a firewall. But I could not see any option that addresses the above intention, i.e., just limit the connection to specified speed.

  • 3
    The method will be dependent of the equipment used. It require either a router that had the needed features (on topic here) or some trick on the machine than run the application (off topic here). Can you give more details on your network equipment? – JFL Mar 3 '17 at 7:54
  • I was thinking the way that NetBalancer or NetLimiter do, but doing the same without third party application. Reading the comments, if you think there is better place rather than here please migrate it. I thought this question fits here. – Developer Mar 3 '17 at 22:04
  • Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you could provide and accept your own answer. – Ron Maupin Aug 17 '17 at 3:48
1

Please provide more information on the question and the Network environment.Also tell us in which device you are planning to do the bandwidth limiting.

You can use the netstat or identify the ports which are being used by the application and then apply tc rules based on the ports.

If you are using a Linux based Desktop/Router then you can do a Token Bucket Filter with TC commands. It can slow down traffic for a given port and services on Desktop or OpenWRT based routers.

When traffic is shaped, its rate of transmission is under control, in other words you apply some sort of bandwidth allocation for each port.

A Sample Use Case: Commands for throttling Upload 2mbit and Download 4mbit for OpenWRT based Router.We can modify the same set of commands once we know what is the type of service/exe we are looking at here.

Upload Bandwidth Limiting: tc qdisc add dev eth0 root tbf rate 2mbit burst 10kb latency 50ms peakrate 4mbit minburst 1540

Download Bandwidth Limiting: tc qdisc add dev br-lan root tbf rate 4mbit burst 10kb latency 50ms peakrate 8mbit minburst 1540

| improve this answer | |
  • Host or server configurations are off-topic here. – Ron Maupin Mar 3 '17 at 13:38
  • As I explained in the comment above, I was thinking to benefit from some local code (not third party applications nor specific hardware) to achieve my goal. – Developer Mar 3 '17 at 22:06
  • @Developer, product or resource recommendations are explicitly off-topic here, as are servers, applications, and programming. – Ron Maupin Aug 17 '17 at 3:49

Not the answer you're looking for? Browse other questions tagged or ask your own question.