LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 01-17-2007, 03:27 AM   #1
sharon179
LQ Newbie
 
Registered: Jan 2007
Posts: 2

Rep: Reputation: 0
Question How can i limit the bandwidth of application? (like CURL)


HI!

WHat is the best way (and easy :-) to limit the bandwidth of linux application?

For example:

I want that, when using FTP (with "curl" client) , and using a Gbit card, to limit the bandwidth just to 300 Mbit.

???
 
Old 01-17-2007, 05:38 AM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 26,534
Blog Entries: 51

Rep: Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603Reputation: 2603
Hello and welcome to LQ.

First of all, "best" and "easy" are terms relative to your experience so YMMV(VM). Secondly (expectation-wise) AFAIK there is no "good" way to limit inbound traffic (but do check the LARTC site) since you have no direct control over what is sent to you. And apps that support "rate limiting" like 'wget' do this in (IIRC) a "crude" way by using 'usleep' ('man wget'). In short you can *try* to shape inbound by shaping outbound traffic since you control that. In short you set up your ehternet device with a longer queue length, set up iptables rules to divide traffic any way you want (modules for network, owner, sid, whatever is available to you) and mark them, and then use 'tc' (iproute2 package) to add some rules which take the marks as dividers. I'm pretty sure this topic has been beaten to death and way beyond so a wee search of LQ should unearth interesting threads and possibly (pointers to) scripts. Else there's shaper scripts at the LARTC site, SourceForge.net or Freshmeat.net.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Limit Bandwidth zmileta Linux - Hardware 3 11-15-2006 11:57 PM
How to limit my own bandwidth? hafilip Debian 4 07-23-2006 06:24 AM
Bandwidth limit marius_vl Linux - Networking 1 06-20-2006 08:04 AM
bandwidth limit matrix_x Linux - Networking 1 12-05-2005 04:54 PM
Vsftpd - how to limit download bandwidth but unlimited upload bandwidth? mpls mikeg Linux - Software 3 08-13-2005 01:52 PM


All times are GMT -5. The time now is 10:54 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration