RouterOS优化

Web 80端口优先
/ip firewall mangle
add chain=prerouting protocol=tcp dst-port=80 action=mark-packet new-packet-mark=web passthrough=yes comment="web" disabled=no

/queue tree
add name="web" parent=ether1-WAN packet-mark="web" limit-at=0 queue=default priority=3 max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no

小包优先
/ ip firewall mangle
add chain=forward protocol=tcp tcp-flags=syn action=change-mss new-mss=1440 comment="" disabled=no
add chain=forward p2p=all-p2p action=mark-connection new-connection-mark=p2p_conn passthrough=yes comment="" disabled=no
add chain=forward connection-mark=p2p_conn action=mark-packet new-packet-mark=p2p passthrough=yes comment="" disabled=no
add chain=forward connection-mark=!p2p_conn action=mark-packet new-packet-mark=general passthrough=yes comment="" disabled=no
add chain=forward packet-size=32-512 action=mark-packet new-packet-mark=small passthrough=yes comment="" disabled=no
add chain=forward packet-size=512-1200 action=mark-packet new-packet-mark=big passthrough=yes comment="" disabled=no
/ queue tree
add name="p2p1" parent=ether1-WAN packet-mark=p2p limit-at=2000000 queue=default priority=8 max-limit=2000000 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="p2p2" parent=ether2-LAN packet-mark=p2p limit-at=2000000 queue=default priority=8 max-limit=2000000 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="ClassA" parent=ether2-LAN packet-mark="" limit-at=0 queue=default priority=8 max-limit=100000000 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="ClassB" parent=ClassA packet-mark="" limit-at=0 queue=default priority=8 max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="Leaf1" parent=ClassA packet-mark=general limit-at=0 queue=default priority=7 max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="Leaf2" parent=ClassB packet-mark=small limit-at=0 queue=default priority=5 max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="Leaf3" parent=ClassB packet-mark=big limit-at=0 queue=default priority=6 max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no


1-8级优先级控制,数字越小优先级越高

LAN 内网接口
WAN 外网接口
SMALL 小包 32-512字节 5级优先级
BIG 大包 512-1200字节 6级优先级
general 其它包 1200-1500字节 7级优先级
P2P类 8级优先,全局限速 200KB/S下载
Leaf 子类

转载于:https://www.cnblogs.com/seawwh/articles/2322175.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值