`
zuroc
  • 浏览: 1307517 次
  • 性别: Icon_minigender_1
  • 来自: 江苏
社区版块
存档分类
最新评论

随笔...

阅读更多
1.
交换机的东西我一点不懂

今晚学了一点.

100M 电信带宽, 50M 网通带宽

需求:
用 acl 将两种流量区分来做 qos
在光纤口自己限制住 100M + 50M
入的方向有X台机器, 希望带宽可以按应用定优先级, 然后在出的接口控制流量

解决方案:
在入的方向配acl
local-precedence是本地优先级
如果有多条acl区分不同的流,就要配多条traffic-priority命令

出方向配traffic-shape 500000 12 ,
traffic-shape ?
INTEGER<20-1000000> Maximal transmit rate (Kbps).
queue Queue

入方向配qos-acl
之所以在出口限速,
因为ISP提供带宽比交换机端口线速要小

qos-acl是这样用的:
interface GigabitEthernet2/1/2 port access vlan 10 traffic-priority inbound ip-group 3000 rule 0 system-index 3 remark-policed-service untrusted dscp 0 cos 0 local-precedence 1 drop-priority 1

local-precedence是本地优先级
如果有多条acl区分不同的流,就要配多条traffic-priority命令

配了traffice-priority来把不同流标记为不同优先级之后,不同优先级的包就进不同的队列了

比如从千兆端口出去的时候,你只有50m的ISP带宽,就要限一下速度,因为交换机以为你有1000m的总带宽

2.
网游很赚钱

3.

nginx upload progress 用法备忘

http://blog.new-bamboo.co.uk/2007/11/23/upload-progress-with-nginx
"""
If you're going to upload files of any considerable size you'll also want to the max_body_side to something reasonable.
"""


user work work;
worker_processes 4;
pid logs/nginx.pid;

worker_rlimit_nofile 65535;
events {
use epoll;
worker_connections 2048;
}
http {
upload_progress proxied 1m;
include mime.types;
default_type application/octet-stream;
keepalive_timeout 65;

server {
listen 12345;
server_name localhost;

location / {
root /xxx/xxx;
proxy_pass http://xxx.xxx.xxx.xxx:xxx;
track_uploads proxied 30s;
client_max_body_size 500m;
}

location ^~ /progress {
report_uploads proxied;
}

}
}
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics