|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?注册
×
本帖最后由 weisms 于 2009-5-27 10:39 编辑
网络是2跟10M网通和一根电信10M。自己瞎琢磨做的,有些心里没谱,不知道对不,现实效果还是不错的,下载网通的能有2M多的速度,电信也能够策略。我把我路由上的命令贴出来,希望大家看看有没有问题,有更好的方法希望高手说下。断线切换我用的是脚本,就不贴了,很简单,切换网关就行了。
0 chain=forward protocol=tcp tcp-flags=syn action=change-mss new-mss=1440
1 chain=prerouting in-interface=nei connection-state=new nth=1,1,0
dst-address-list=CNC action=mark-connection new-connection-mark=odd
passthrough=yes
2 chain=prerouting in-interface=nei connection-mark=odd action=mark-routing
new-routing-mark=odd passthrough=no
3 chain=prerouting in-interface=nei connection-state=new nth=1,1,1
dst-address-list=CNC action=mark-connection new-connection-mark=even
passthrough=yes
4 chain=prerouting in-interface=nei connection-mark=even action=mark-routin>
new-routing-mark=even passthrough=no
5 chain=prerouting src-address=192.168.0.0/24 dst-address-list=TEL
action=mark-routing new-routing-mark=TEL passthrough=no
1 chain=srcnat src-address=192.168.0.0/24 connection-mark=even
action=src-nat to-addresses=网通1 to-ports=0-65535
2 chain=srcnat src-address=192.168.0.0/24 connection-mark=even
action=src-nat to-addresses=网通2 to-ports=0-65535
3 chain=srcnat src-address=192.168.0.0/24 action=src-nat
to-addresses=电信 to-ports=0-65535
4 chain=srcnat src-address=192.168.9.0/24 action=src-nat
to-addresses=电信 to-ports=0-65535
/ ip route
add dst-address=0.0.0.0/0 gateway=网通1网关 scope=255 target-scope=10 \
routing-mark=odd comment="cnc1" disabled=no
add dst-address=0.0.0.0/0 gateway=网通2网关scope=255 target-scope=10 \
routing-mark=even comment="cnc2" disabled=no
add dst-address=0.0.0.0/0 gateway=网通2网关scope=255 target-scope=10 \
comment="CNC" disabled=no
add dst-address=0.0.0.0/0 gateway=电信网关 scope=255 target-scope=10 \
routing-mark=TEL comment="tel" disabled=no |
|