码迷,mamicode.com
首页 > 其他好文 > 详细

nginx 下载限速

时间:2015-04-07 19:47:30      阅读:129      评论:0      收藏:0      [点我收藏+]

标签:nginx

You should include a directive like this in your nginx configuration file (inside the block of your server configuration):

limit_rate 150k;

This limits the speed of transmission of the answer to client. It works as a limit for each connection, not for the total server transfer rate. (Maybe you can adjust max_clients = worker_processes *worker_connections as a work-around to limit total transfer.)

Take a look at nginx documentation for limit_rate. There is also a limit_rate_after directive that is useful to set this limit only after download exceeds certain size.

nginx 下载限速

标签:nginx

原文地址:http://blog.csdn.net/hellochenlian/article/details/44923443

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!