Subject: Re: Cool feature: FTP rate throttling
To: Emre Yildirim <emre.yildirim@us.army.mil>
From: Luke Mewburn <lukem@wasabisystems.com>
List: netbsd-users
Date: 04/11/2001 10:23:40
On Tue, Apr 10, 2001 at 11:05:17AM -0500, Emre Yildirim wrote:
> On Tuesday 10 April 2001 08:31 US Central Time, Johnny C. Lam wrote:
> > I'm not sure how many people use this feature in our FTP client in
> > this day and age of high-speed Internet access, but for those of us
> > like myself, stuck in areas that get neither cable broadband nor
> > DSL and thus required to use a modem, FTP rate throttling is
> > super-useful. Using "rate all 2048", I can limit FTP throughput to
> > 2KB/s on my 33.6K baud rate connection and thus preserve enough
> > bandwidth to surf the web using links or ssh to various places and
> 
> This is kinda cool.  But there doesn't seem to be such a feature in 
> the FTP daemon.  I would be really nice to limit all uploads on the 
> FTP server to, let's say 25KB/sec, without using ALTQ or something 
> similar.  Maybe something in /etc/ftpd.conf that controls at how much 
> bandwidth the FTP server uploads.  Is this already implemented?  If 
> not, wouldn't this be a good idea?

The NetBSD ftp server (ftpd) does have this feature.

An administrator can add an entry to /etc/ftpd.conf like:
	rateput guest	5k
which will throttle uploads to the server by users in the `guest'
class (usually anonymous ftp) to 5 KB/s. `rateget' exists for
download limits.

A remote user can request a specific rate (e.g, if their ftp client
doesn't support this) with:
	site rateput 5k

This feature has existing in NetBSD ftp servers since NetBSD 1.5.

--
Luke Mewburn  <lukem@wasabisystems.com>  http://www.wasabisystems.com
Luke Mewburn     <lukem@netbsd.org>      http://www.netbsd.org
Wasabi Systems - providing NetBSD sales, support and service.