找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 1311|回复: 3

[其它] P2P Problem

[复制链接]
发表于 2005-7-5 08:48:16 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?注册

×
P2P Problem


/ip firewall mangle
add chain=forward p2p=all-p2p action=mark-packet new-packet-mark=allp2p comment="" disabled=no
/ip firewall filter
add chain=forward packet-mark=allp2p action=jump jump-target=P2P comment="P2P" disabled=no
add chain=P2P protocol=tcp tcp-flags=syn connection-limit=10,32 action=drop comment="" disabled=no
/ ip firewall connection tracking
set enabled=yes tcp-syn-sent-timeout=2m tcp-syn-received-timeout=1m tcp-established-timeout=5m tcp-fin-wait-timeout=2m tcp-close-wait-timeout=1m \
tcp-last-ack-timeout=30s tcp-time-wait-timeout=2m tcp-close-timeout=10s udp-timeout=30s udp-stream-timeout=3m icmp-timeout=30s generic-timeout=10m

= 10 connection per IP for P2P
routeros
发表于 2005-7-5 23:01:24 | 显示全部楼层
QUOTE(lovellh @ Jul 5 2005, 08:48 AM)
P2P Problem


/ip firewall mangle
add chain=forward p2p=all-p2p action=mark-packet new-packet-mark=allp2p comment="" disabled=no
/ip firewall filter
add chain=forward packet-mark=allp2p action=jump jump-target=P2P comment="P2P" disabled=no
add chain=P2P protocol=tcp tcp-flags=syn connection-limit=10,32 action=drop comment="" disabled=no
/ ip firewall connection tracking
set enabled=yes tcp-syn-sent-timeout=2m tcp-syn-received-timeout=1m tcp-established-timeout=5m tcp-fin-wait-timeout=2m tcp-close-wait-timeout=1m \
tcp-last-ack-timeout=30s tcp-time-wait-timeout=2m tcp-close-timeout=10s udp-timeout=30s udp-stream-timeout=3m icmp-timeout=30s generic-timeout=10m

= 10 connection per IP for P2P
[right][snapback]53135[/snapback][/right]


好!
routeros
回复

使用道具 举报

发表于 2005-7-6 08:37:12 | 显示全部楼层
能用吗
routeros
回复

使用道具 举报

发表于 2005-7-6 22:34:44 | 显示全部楼层
嘿嘿。。看看我的P2P限制方法。。很管用。
/ip firewall mangle
0   ;;; p2p Rule
     in-interface=530wan1 p2p=all-p2p action=accept mark-flow=p2p_in

1   in-interface=530lan1 p2p=all-p2p action=accept mark-flow=p2p_out

2   in-interface=139lan2 p2p=all-p2p action=accept mark-flow=p2p_out

3 X in-interface=isalan3 p2p=all-p2p action=accept mark-flow=p2p_out

/queue tree
0    name="P2P-IN1" parent=530lan1 flow=p2p_in limit-at=0 queue=PCQ-Download priority=8
      max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0

1    name="P2P-OUT" parent=530wan1 flow=p2p_out limit-at=0 queue=PCQ-Upload priority=8
      max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0

3    name="P2P-IN2" parent=139lan2 flow=p2p_in limit-at=0 queue=PCQ-Download priority=8
      max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0

4    name="P2P-IN3" parent=isalan3 flow=p2p_in limit-at=0 queue=PCQ-Download priority=8
      max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0



/queue type
1 name="PCQ-Download" kind=pcq bfifo-limit=15000 pfifo-limit=10 red-limit=60
   red-min-threshold=10 red-max-threshold=50 red-burst=20 sfq-perturb=5 sfq-allot=1514
   pcq-rate=256000 pcq-limit=50 pcq-classifier=dst-address

2 name="PCQ-Upload" kind=pcq bfifo-limit=15000 pfifo-limit=10 red-limit=60
   red-min-threshold=10 red-max-threshold=50 red-burst=20 sfq-perturb=5 sfq-allot=1514
   pcq-rate=64000 pcq-limit=50 pcq-classifier=src-address
routeros
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|手机版|小黑屋|软路由 ( 渝ICP备15001194号-1|渝公网安备 50011602500124号 )

GMT+8, 2024-11-17 17:44 , Processed in 0.087571 second(s), 4 queries , Gzip On, Redis On.

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表