二种方法都能实现跳转,
我的网络是内网IP分流,
# jul/08/2012 13:59:56 by RouterOS 3.30
# software id = PIYV-S309
#
/ip firewall mangle
add action=add-src-to-address-list address-list=src2 address-list-timeout=1s \
chain=prerouting comment=”" disabled=no dst-port=80 protocol=tcp \
src-address=192.168.1.2-192.168.1.250 src-address-list=!src1
add action=add-src-to-address-list address-list=src1 address-list-timeout=1m \
chain=prerouting comment=”" disabled=no dst-port=80 protocol=tcp \
src-address=192.168.1.2-192.168.1.250 src-address-list=src2
/ip firewall nat
add action=redirect chain=dstnat comment=”" disabled=no dst-port=80 protocol=\
tcp src-address-list=src2 to-ports=8080
/ip proxy
set always-from-cache=no cache-爱的米istrator=webmaster cache-hit-dscp=4 \
cache-on-disk=no enabled=yes max-cache-size=unlimited \
max-client-connections=600 max-fresh-time=3d max-server-connections=600 \
parent-proxy=0.0.0.0 parent-proxy-port=0 port=8080 serialize-connections=\
no src-address=0.0.0.0
/ip proxy access
add action=deny comment=”" disabled=no dst-port=80 redirect-to=\
192.168.1.252/index.html
这方法的mangle的顺序别搞错。
另一方法
ROS首页强开配置
/ip firewall nat
add action=dst-nat chain=dstnat comment=ToAddress disabled=no dst-port=80 protocol=tcp src-
address-list=src1 to-addresses=210.45.2.216 to-ports=80
/ip firewall mangle
add action=add-src-to-address-list address-list=src1 address-list-timeout=3s chain=prerouting
comment=TimeOut1 disabled=no dst-port=80 protocol=tcp src-address-list=!src2
add action=add-src-to-address-list address-list=src2 address-list-timeout=3h chain=prerouting
comment=TimeOut2 disabled=no dst-port=80 protocol=tcp src-address-list=src1
备注:
1,210.45.2.216为内网首页强开WEB服务器IP。
2,强开3秒,强开过的IP在3小时内不会再强开。