ProFTPD和WU-FTP的BANDWIDTH控制
2007-06-12 00:00:00 来源:WEB开发网+ * at 2048 Bytes/sec. + * - if there is three or more connections, each files will be
+ * transfered at "4096/connections" Bytes/sec. + * + * Note : If transfer file size is lower than the "MaxBandWidth" rate , + * it will ignore the limit. + * + * - MinBandWidth + * Syntax : MinBandWidth + * Default : none + * Context : server config,, + * + * Set a minimal bandwidth to use for file-transfer. (retr only) + * This over-ride both BandWidth and MaxBandWidth rules as well + * as the calculated rate based on the number of connections. + * + * The is in Bytes/second. + * A of "0" means no bandwidth limit. + * + * Example : + * If BandWidth is set to "3072" (2KBytes/sec) and MinBandWidth + * is set to "1024" (1KBytes/sec) that means : + * - if there is one connection, the file will be transfered + * at 3072 Bytes/sec. + * - if there is two connections, each files will be transfered
+ * at 1536 Bytes/sec. + * - if there is three or more connections, each files will be
+ * transfered at 1024 Bytes/sec. (Minimal of 1024 Bytes/sec).
+ * + * Note : If transfer file size is lower than the "MinBandWidth" rate , + * it will ignore the limit. + * + */ + #include "conf.h" #ifdef HAVE_REGEX_H #include #endif +#include + +#undef timerisset +#define timerisset(tvp) ((tvp)->tv_sec || (tvp)->tv_us ec) +#undef timerclear +#define timerclear(tvp) ((tvp)->tv_sec tvp)->tv_usec □
更多精彩
赞助商链接