找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 4573|回复: 1

[其它] 肌肉男来

[复制链接]
发表于 2010-4-5 19:38:58 | 显示全部楼层 |阅读模式

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

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

×
本帖最后由 横山居石 于 2010-4-5 19:49 编辑

ros 2.9.27 PPOE根据人数限速,设置网段10.10.10.0/24

问题:放入scheduler运行时间设置一分钟,无法运行,且之前在scheduler里面可以运行的都不能运行了
在终端里面运行是没有问题的,我现在就郁闷了,你的那个代码我又看不懂,希望过路的大哥们指点一下!!!

代码如下:

:set user1 [/pp ac p c ]
#以下是删除代码,必段先在Queues里有10.10.10.0/24段的限速些代码才能正常运行
:for ok from=1 to=254 do={queue simple remove ("YES" . $ok)}
:if ($user1 < 4) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=256000/2048000 burst-limit=256000/3072000 burst-threshold=256000/2048000 burst-time=20s/20s \ interface=all}
}
:if ($user1 < 6) do={
:if ($user1 >= 4) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=200000/1500000 burst-limit=240000/1800000 burst-threshold=200000/1500000 burst-time=20s/20s \ interface=all}
}}
:if ($user1 < 8) do={
:if ($user1 >= 6) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=150000/1100000 burst-limit=200000/1500000 burst-threshold=150000/1100000 burst-time=20s/20s \ interface=all}
}}
:if ($user1 < 10) do={
:if ($user1 >= 8) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=120000/900000 burst-limit=150000/1200000 burst-threshold=120000/900000 burst-time=20s/20s \ interface=all}
}}
:if ($user1 < 12) do={
:if ($user1 >= 10) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=80000/800000 burst-limit=120000/900000 burst-threshold=80000/800000 burst-time=20s/20s \ interface=all}
}}
:if ($user1 < 14) do={
:if ($user1 >= 12) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=70000/700000 burst-limit=80000/800000 burst-threshold=70000/700000 burst-time=20s/20s \ interface=all}
}}
:if ($user1 < 16) do={
:if ($user1 >= 14) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=64000/600000 burst-limit=70000/700000 burst-threshold=64000/600000 burst-time=20s/20s \ interface=all}
}}
:if ($user1 < 18) do={
:if ($user1 >= 16) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=55000/550000 burst-limit=60000/600000 burst-threshold=55000/550000 burst-time=20s/20s \ interface=all}
}}
:if ($user1 >= 18) do={
:for ok from 1 to 254 do={/queue simple add name=(YES . $ok) target-address=(10.10.10. . $ok) limit-at=0/0 max-limit=55000/512000 burst-limit=60000/512000 burst-threshold=55000/512000 burst-time=20s/20s \ interface=all}
}


另外诚心请教,PPOE限制某一个账号只能上一个网站,其它都封掉,不要笑,本人菜鸟学习中,谢谢!!!
routeros
发表于 2010-4-5 21:48:54 | 显示全部楼层
你的ros或者硬件有问题,见过有脚本不能运行的
routeros
回复

使用道具 举报

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

本版积分规则

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

GMT+8, 2024-12-23 03:24 , Processed in 0.041138 second(s), 4 queries , Gzip On, Redis On.

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

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