Skip to main content

Limiting bandwidth

During large file transfers we may want to limit maximum bitrate of transfer. If the network is shared with other users and applications, we may want to avoid hogging all the available capacity for our transfer. Of course, the network could and should handle this (ie. using QoS, quality of service), but it requires fairly complex network setup and competent network administrator. In case they are absent, we might simply limit ourselves.

The Sftp class has MaxUploadSpeed and MaxDownloadSpeed which can be set to the appropriate value in kilobytes per second (or to zero, if no limiting is desired).