安装 和 基本设置我就不说了
主要 想说说 上网 控制这一方面
  1 禁止 未授权用户上网;呵呵 也就是 没收钱的 用户 呵呵
       首先 需要绑定已经授权的 ip 然后就要用到 地址列表了 新建 地址列表 为 VIP 然后 加入 已授权 用户IP
然后 防火墙 添加

/ ip firewall filter
add chain=forward in-interface=lan src-address-list=!VIP action=drop
    comment="" disabled=no

意思就是禁止非VIP 地址列表上网  呵呵 很简单的一个 例子 靠这一条 拦截了 不少 非法之徒 当然这对于下面客户 是 交换机是 起作用的 要是 客户在 下面加路由 呵呵 MAC 修改那也 是没有 办法的 就限制连接数吧 呵呵只要他 受的了 管他呢 不要 做的太绝
2 限制一些连接 如P2P 下载软件
首先是 P2P啦 我这里是 分时段 禁止 发现规则里的 时间控制貌似 用不了 我的2927
新建规则
/ ip firewall filter
add chain=forward p2p=all-p2p action=drop comment="No_P2P" disabled=no
全部P2P连接禁止注释为No_P2P 然后系统 新建调度程序
No_P2P
设置一个 启动时间 如19点 间隔一天 这样每天 19点开始禁止P2P
/ip fir fil set [/ip fir fil find com="No_P2P"] disabled=no
/ip firewall connection remove [/ip firewall connection find connection-mark=p2p_conn]
上面有2条规则
/ip firewall connection remove [/ip firewall connection find connection-mark=p2p_conn]
是 做了小包优化那个 P2P 标记的 运行时候删除所有 已经连接的p2p_conn标记的连接 老实说我的2927 对 P2P 也是 限制不死
然后需要 在 指定时间开启P2P
调度程序 规定的 时间运行 也是 间隔时间 和禁止的时间一样吧 随便你发挥啦 给个思路就好了
/ip fir fil set [/ip fir fil find com="No_P2P"] disabled=yes
迅雷 新建
/ ip firewall filter
add chain=forward action=jump jump-target=xl comment="xunlei" disabled=no
新建一个跳转 跳转到 lx 链 当然你要 建立 lx 链如
/ ip firewall filter
add chain=xl dst-address=219.129.83.0/24 action=drop
    comment="Blockade_Thunder" disabled=no
add chain=xl dst-address=220.172.191.36 action=drop comment="" disabled=no
add chain=xl dst-address=61.183.55.0/24 action=drop comment="" disabled=no
add chain=xl dst-address=58.61.39.0/24 action=drop comment="" disabled=no
add chain=xl protocol=tcp dst-port=3076-3079 action=drop comment=""
    disabled=no
add chain=xl protocol=udp dst-port=3076-3079 action=drop comment=""
    disabled=no
add chain=xl dst-address=221.238.253.251 action=accept comment="Login IP"
    disabled=no
add chain=xl dst-address=221.238.252.0/24 protocol=tcp dst-port=80 action=drop
    comment="" disabled=no
add chain=xl protocol=udp dst-port=5004 action=drop comment="" disabled=no
add chain=xl protocol=tcp dst-port=5200 action=drop comment="" disabled=no
add chain=xl protocol=udp src-port=15000-15001 action=drop comment=""
    disabled=no
add chain=xl protocol=tcp dst-port=4661-4662 action=drop comment="No Emule"
    disabled=no
add chain=xl protocol=tcp dst-port=4242 action=drop comment="" disabled=no
add chain=xl dst-address=62.241.53.15 action=drop comment="" disabled=no
add chain=xl protocol=tcp dst-port=16881 action=drop comment="No BitSpirit"
    disabled=no
add chain=xl dst-address=60.190.236.0/24 action=drop comment="No PPlive TV"
    disabled=no
add chain=xl protocol=udp src-port=13404 action=drop comment="" disabled=no
然后也是规定时间 开启
调度程序规定时间 开启跳转
/ip fir fil set [/ip fir fil find com="xunlei"] disabled=no
规定 是关闭跳转
/ip fir fil set [/ip fir fil find com="xunlei"] disabled=yes
2 软件的数据标记
  小包策略相信大家应该都有 所耳闻了吧 有没有作用老实就我个人的 网络 环境感受不到效果什么的
接下来我要说的 是 真真切切可以 直接看到效果 的
首先
/ ip firewall mangle
add chain=forward protocol=tcp tcp-flags=syn action=change-mss new-mss=1400
    comment="MMS" disabled=no
mms 1400很重要 以下基本是 依据这个数据来了 要是这个修改了那很多数据基本要重新测了
以下是 本人亲自测验的数据库 在此首发当然 用点心思的基本都能做到想到的
首先什么呢 QQ旋风吧 在MMS 是1400的环境下
QQ旋风 数据包大小1078
/ ip firewall mangle
add chain=forward packet-size=1078 action=mark-packet new-packet-mark=1078
    passthrough=yes comment="xuanfeng" disabled=no
酷狗 数据包大小1084
/ ip firewall mangle
add chain=forward packet-size=1084 action=mark-packet new-packet-mark=1084
    passthrough=yes comment="kugou" disabled=no
大名顶顶的迅雷了 1468
/ ip firewall mangle
add chain=forward packet-size=1468 action=mark-packet new-packet-mark=1468
    passthrough=yes comment="xunlei" disabled=no
以下是 端口标记
有 QQ 常见游戏端口
/ ip firewall mangle
add chain=forward protocol=tcp dst-port=443 action=mark-packet
    new-packet-mark=qq passthrough=yes comment="qq" disabled=no
add chain=forward protocol=tcp src-port=443 action=mark-packet
    new-packet-mark=qq passthrough=yes comment="" disabled=no
add chain=forward protocol=udp src-port=4000-4005 dst-port=8000-8005
    action=mark-packet new-packet-mark=qq passthrough=yes comment=""
    disabled=no
add chain=forward protocol=udp src-port=6000-6010 dst-port=8000-8005
    action=mark-packet new-packet-mark=qq passthrough=yes comment=""
    disabled=no
add chain=forward protocol=udp src-port=8000-8005 dst-port=4000-4005
    action=mark-packet new-packet-mark=qq passthrough=yes comment=""
    disabled=no
add chain=forward protocol=udp src-port=8000-8005 dst-port=6000-6010
    action=mark-packet new-packet-mark=qq passthrough=yes comment=""
    disabled=no
add chain=forward protocol=tcp dst-port=3724 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="wow" disabled=no
add chain=forward protocol=tcp src-port=3724 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="" disabled=no
add chain=forward protocol=tcp dst-port=80 content=html action=mark-packet
    new-packet-mark=80 passthrough=yes comment="http" disabled=no
add chain=forward protocol=tcp src-port=80 content=html action=mark-packet
    new-packet-mark=80 passthrough=yes comment="" disabled=no
add chain=forward protocol=udp dst-port=39311 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="feic" disabled=no
add chain=forward protocol=udp src-port=39311 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="" disabled=no
add chain=forward protocol=tcp dst-port=25510-25525 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="au" disabled=no
add chain=forward protocol=tcp src-port=25510-25525 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="" disabled=no
add chain=forward protocol=tcp dst-port=28688 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="dahuaixiyou" disabled=no
add chain=forward protocol=tcp src-port=28688 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="" disabled=no
add chain=forward protocol=tcp dst-port=32388 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="" disabled=no
add chain=forward protocol=tcp src-port=32388 action=mark-packet
    new-packet-mark=yx passthrough=yes comment="" disabled=no
3 OK  了数据包是 标记出来了 那么 现在对 标记出来的数据包 做 优先和 限速
限制旋风数据包 1078连接速度 为640K 当然根据你自己的网络环境设置啦 注意是最大 级别8
LB 是 父系如果你没有做 小包的话 就改成你的内网网卡名吧
/ queue tree
add name="L1078" parent=LB packet-mark=1078 limit-at=0 queue=default
    priority=8 max-limit=640000 burst-limit=0 burst-threshold=0 burst-time=0s
    disabled=no
酷狗 1084标记 800K 呵呵级别8
add name="L1084" parent=LB packet-mark=1084 limit-at=0 queue=default
    priority=8 max-limit=800000 burst-limit=0 burst-threshold=0 burst-time=0s
    disabled=no
迅雷 1468 1500K 级别8
add name="L1468" parent=LB packet-mark=1468 limit-at=0 queue=default
    priority=8 max-limit=1500000 burst-limit=0 burst-threshold=0 burst-time=0s
    disabled=no
QQ 标记类 不限速度 优先1级
add name="Lqq" parent=LB packet-mark=qq limit-at=0 queue=default priority=1
    max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
游戏也是 一样
add name="Lyx" parent=LB packet-mark=yx limit-at=0 queue=default priority=1
    max-limit=0 burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
还可以 做一下网页标记
规则是
TCP 80端口
内包含
HTML 字样
标记
然后也是 queue 优先 =======