jiansuper 发表于 2008-7-7 12:04:14

[请教]做PCQ限速后,ROS的FTP服务器上传只有几K

/ queue type
set default name="default" kind=pfifo pfifo-limit=50
set ethernet-default name="ethernet-default" kind=pfifo pfifo-limit=50
set wireless-default name="wireless-default" kind=sfq sfq-perturb=5 sfq-allot=1514
set synchronous-default name="synchronous-default" kind=red red-limit=60 red-min-threshold=10 red-max-threshold=50 red-burst=20 red-avg-packet=1000
set hotspot-default name="hotspot-default" kind=sfq sfq-perturb=5 sfq-allot=1514
add name="PCQ_Down" kind=pcq pcq-rate=0 pcq-limit=50 pcq-classifier=dst-address pcq-total-limit=2000
add name="PCQ_Up" kind=pcq pcq-rate=64000 pcq-limit=50 pcq-classifier=src-address pcq-total-limit=2000
add name="default-small" kind=pfifo pfifo-limit=2000

/ queue simple
add name="PCQ_Main" target-address=192.168.1.0/24 dst-address=0.0.0.0/0 \
    interface=all parent=none direction=both priority=8 queue=PCQ_Up/PCQ_Down limit-at=0/0 \
    max-limit=512000/2000000 total-queue=default-small disabled=no
add name="Slow" target-address=192.168.1.0/24 dst-address=0.0.0.0/0 \
    interface=all parent=PCQ_Main packet-marks=mark_slow direction=both priority=8 \
    queue=PCQ_Up/PCQ_Down limit-at=0/0 max-limit=256000/1250000 total-queue=default-small \
    disabled=no
add name="Fast" target-address=192.168.1.0/24 dst-address=0.0.0.0/0 \
    interface=all parent=PCQ_Main packet-marks=mark_fast direction=both priority=1 \
    queue=PCQ_Up/PCQ_Down limit-at=0/0 max-limit=512000/2000000 total-queue=default-small \
    disabled=no
add name="Midd" target-address=192.168.1.0/24 dst-address=0.0.0.0/0 \
    interface=all parent=PCQ_Main packet-marks=mark_midd direction=both priority=5 \
    queue=PCQ_Up/PCQ_Down limit-at=0/0 max-limit=256000/2000000 total-queue=default-small \
    disabled=no


/ ip firewall mangle
add chain=prerouting action=mark-packet new-packet-mark=mark_slow passthrough=yes comment="Mark All" disabled=no
add chain=prerouting protocol=tcp dst-port=8291 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="winbox" disabled=no
add chain=prerouting protocol=icmp action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="DNS" disabled=no
add chain=prerouting protocol=udp dst-port=53 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="" disabled=no
add chain=prerouting protocol=tcp dst-port=8139 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="    " disabled=no
add chain=prerouting protocol=tcp dst-port=7709 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="" disabled=no
add chain=prerouting protocol=tcp dst-port=7711 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="" disabled=no
add chain=prerouting protocol=tcp dst-port=8601 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="" disabled=no
add chain=prerouting protocol=tcp dst-port=22220-22230 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="" disabled=no
add chain=prerouting protocol=udp dst-port=8000-8008 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="QQ" disabled=no
add chain=prerouting protocol=udp dst-port=27000-27100 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="games CS" disabled=no
add chain=prerouting protocol=tcp dst-port=443 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="games qq https " disabled=no
add chain=prerouting protocol=tcp dst-port=6020-6100 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="games zhengtu" disabled=no
add chain=prerouting protocol=tcp dst-port=9010-9020 action=mark-packet new-packet-mark=mark_fast passthrough=yes comment="games wendao" disabled=no
add chain=prerouting src-address=192.168.1.0/24 protocol=tcp dst-port=80 src-address-list=!src2 action=add-src-to-address-list address-list=src1 \
    address-list-timeout=3s comment="TimeOut1" disabled=no
add chain=prerouting src-address=192.168.1.0/24 protocol=tcp dst-port=80 action=add-src-to-address-list address-list=src2 address-list-timeout=3h \
    comment="TimeOut2" disabled=no
add chain=prerouting dst-address=192.168.1.1 protocol=tcp dst-port=9999 action=add-src-to-address-list address-list=handlimit address-list-timeout=1h \
    comment="      " disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.gif action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="AutoWeb80" \
    disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.jpg action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="" \
    disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.htm action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="" \
    disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.html action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="" \
    disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.asp action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="" \
    disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.aspx action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="" \
    disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.php action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="" \
    disabled=no
add chain=prerouting protocol=tcp dst-port=80 content=.swf action=add-dst-to-address-list address-list=web80 address-list-timeout=5m comment="" \
    disabled=no
add chain=prerouting dst-address-list=web80 aaction=mark-packet new-packet-mark=mark_midd passthrough=yes comment="AutoWeb80" disabled=no
add chain=prerouting src-address-list=web80 add chain=prerouting dst-address-list=web80 action=mark-packet new-packet-mark=mark_midd passthrough=yes comment="" disabled=no
add chain=prerouting dst-address-list=web80 action=mark-packet new-packet-mark=mark_midd passthrough=yes comment="" disabled=no

本人双1M ADSL 同网关做了这个PCQ后,迅雷下载可以控制在120K以内,但是上传的速度怎么都只有7到8K包括上传到ROS自带的FTP。那位大大帮我看看是什么问题

wbyz20 发表于 2008-7-7 20:41:55

你这是什么乱七八糟的PCQ限速。不要用简单的队列限速。用队列树限速。。。

wbyz20 发表于 2008-7-7 20:48:13

你自己看看你的网卡先的是什么“”“”“all"速度不是7。8 K才怪。。。 标记的时候先标记外出连接。passthrough=yes全部都是yen   
chain=forwark   
用tree几步都搞定了。还搞这么一大篇,简单的东西搞复杂

jiansuper 发表于 2008-7-8 02:41:41

受教了,能否给个简单的tree例子学习下,我只需要限制p2p下载的速度,web访问不限速

[ 本帖最后由 jiansuper 于 2008-7-8 02:43 编辑 ]

wbyz20 发表于 2008-7-8 22:47:07

p2p限制是比较难的。你可以用Web Proxy
然后用redirect端口转向试下
页: [1]
查看完整版本: [请教]做PCQ限速后,ROS的FTP服务器上传只有几K