找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 4992|回复: 9

[pppoe] ros新课题!电信ADSL(PPPOE)+电信+网通光纤怎么做?

[复制链接]
发表于 2008-5-6 19:27:02 | 显示全部楼层 |阅读模式

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

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

×
现在全国很多地方已经实行了0点断线了,好多网吧到了0点以后要手动换成ADSL的线路,这样很不方便,还有ARP不能双绑了,造成很大的
影响,现在需要这样的陆游教程和方法!
谁能做个教程出来啊?谢谢了!
应该有很多人都需要的,需要的人把老大顶出来!
routeros
发表于 2008-5-6 23:47:49 | 显示全部楼层
在论坛搜一下,各个方面的,然后整合就OK
routeros
回复

使用道具 举报

发表于 2008-5-7 09:38:37 | 显示全部楼层
新贴2.9.X 电信+网通 + 1条ADSL 多线路自动策略路由切换+备份 需要ROS基础知识
本部分设定了隐藏,您已回复过了,以下是隐藏的内容    以后每发帖都会提示1下:技术是不断前进的,保守就等于落后除非你决定这辈子不再前进了

希望 启用这个策略的朋友 在实际使用中的反馈即时和我沟通,包括网通的网关

不一定会很全,但是可以保证100% 能用

第一 ip设好

/ ip address
add address=192.168.1.1/24 network=192.168.1.0 broadcast=192.168.1.255 \
  interface=lan comment="" disabled=no
add address=电信地址/掩码 network=自动设置 broadcast=自动设置
  interface=TEL comment="" disabled=no
add address=网通地址/掩码 network=自动设置 broadcast=自动设置
  interface=CNC comment="" disabled=no

这里如果你有 PPPOE的 ADSL 也可以+上 ADSL

记住要改MSS

/ ip firewall mangle
add chain=forward out-interface=pppoe-out1 protocol=tcp tcp-flags=syn \
  action=change-mss new-mss=1400 comment="" disabled=no

/ ip firewall nat
add chain=srcnat src-address=192.168.1.0/24 action=masquerade comment="" \
  disabled=no

--------------------------------------------------------------------------------------------------

第2步 添加 网通的路由网关

电信的服务器在网络中占了绝大多数

所以不需要考虑电信的服务器

/ ip route
add dst-address=59.80.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.0.0.0/13 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.8.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.10.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.12.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.13.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.13.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.16.0.0/12 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.55.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.208.0.0/13 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.216.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=60.220.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.4.79.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.4.64.0/20 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.48.0.0/13 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.128.210.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.133.0.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.134.98.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.134.108.0/22 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.134.120.0/28 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.134.112.0/20 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.134.96.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.134.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.135.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.136.64.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.137.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.138.128.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.139.128.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.148.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.156.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.158.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.159.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.161.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.161.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.167.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.168.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.176.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.179.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.180.13.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.180.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.181.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.182.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.189.0.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.233.7.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.233.59.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=61.237.148.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.95.98.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.96.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.96.66.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.96.64.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.97.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.98.0.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.99.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.102.128.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.102.224.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.106.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.107.0.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.108.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.110.0.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.110.192.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=202.111.128.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=203.88.200.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=203.88.203.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=203.93.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=203.175.192.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=210.51.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=211.69.0.0/25 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=211.95.192.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=211.97.245.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=211.148.8.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=211.151.130.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=211.158.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=211.163.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.7.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.8.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.12.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.24.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.28.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.56.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.60.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.62.0.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.67.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.68.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.104.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.106.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.107.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.108.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=218.109.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=219.154.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=219.156.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=219.158.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=219.159.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=220.248.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=220.250.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.0.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.4.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.6.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.7.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.7.64.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.7.128.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.8.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.10.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.11.0.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.11.128.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.11.192.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.12.0.0/17 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.12.128.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.13.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.13.64.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.14.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.136.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.192.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.196.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.198.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.199.0.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.199.32.0/20 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.199.128.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.199.192.0/20 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.200.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.204.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.207.0.0/18 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.208.0.0/14 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.212.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.214.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=221.216.0.0/13 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.128.0.0/12 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.160.0.0/15 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.162.0.0/16 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.163.0.0/19 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.173.101.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.173.102.0/23 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.173.104.0/22 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.173.108.0/23 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=222.208.65.0/24 gateway=网通网关 check-gateway=ping \
  distance=0 scope=255 target-scope=10 comment="CNC" disabled=no
add dst-address=0.0.0.0/0 gateway=电信网关 check-gateway=ping distance=0 \
  scope=255 target-scope=10 comment="TEL" disabled=no

(最后这条的意义就是保证在上面找不到网通的网关后 IP包自动走电信的线路 如果想拷贝这个规则 就用替换功能 换上具体的IP就可以了)

-------------------------------------------------------------------------------------------------------

第3步 设置好监控的开关

/ tool netwatch
add host=电信网关 timeout=1s interval=1m up-script=dxup \
  down-script=dxdown comment="TEL" disabled=no
add host=网通网关 timeout=1s interval=1m up-script=CNCup \
  down-script=CNCdown comment="CNC" disabled=no

--------------------------------------------------------------------------------------------------------

第四写好脚本自动切换

/ system script
add name="dxup" source="/ip route set \[/ip route find comment=TEL\] gateway \
  电信网关\n" policy=ftp,reboot,read,write,policy,test,winbox,password

add name="CNCup" source="/ip route set \[/ip route find comment=CNC\] gateway \
  网通网关\n" policy=ftp,reboot,read,write,policy,test,winbox,password

add name="dxdown" source=":if \(\[/tool netwatch get \[/tool netwatch find \
  comment=CNC\] status\]=\"down\"\) do {/ip route set \[/ip route find \
  comment=TEL\] gateway \[/ip address get \[/ip address find \
  interface=pppoe-out1\] network\]} else {/ip route set \[/ip route find \
  comment=TEL\] gateway 网通网关}" \
  policy=ftp,reboot,read,write,policy,test,winbox,password

add name="CNCdown" source=":if \(\[/tool netwatch get \[/tool netwatch find \
  comment=TEL\] status\]=\"down\"\) do {/ip route set \[/ip route find \
  comment=CNC\] gateway \[/ip address get \[/ip address find \
  interface=pppoe-out1\] network\]} else {/ip route set \[/ip route find \
  comment=CNC\] gateway 电信网关}" \
  policy=ftp,reboot,read,write,policy,test,winbox,password

(关键哦 大家要看清楚哦)

最后这些判断有人说我写错了

其实你们没有理解

在电信的 光纤断的 时候 判断1下 网通的光纤是否是断了 (如果也断了就换ADSL)

如果没有断就上 网通的光纤 (反过来 网通的断了也一样)

针对很多地方光纤晚上都会断线的情况

哎 如果不用ADSL 就简单到不能再简单了你们自己去搞

我不想每1点细节都说出来

你们都不用脑的
routeros
回复

使用道具 举报

 楼主| 发表于 2008-5-9 14:27:12 | 显示全部楼层
谢谢!
不过,我刚学ROS,里面的东西很多都不懂!
还要多多请教老师啊!
routeros
回复

使用道具 举报

发表于 2008-5-9 18:00:12 | 显示全部楼层
是好东西,就是看到有点晕~~~~~~~~~~~
routeros
回复

使用道具 举报

发表于 2008-5-12 14:56:36 | 显示全部楼层

收藏下

收藏下,也许以后会用到
routeros
回复

使用道具 举报

 楼主| 发表于 2008-5-28 15:35:45 | 显示全部楼层
已经制作成功!谢谢!
routeros
回复

使用道具 举报

 楼主| 发表于 2008-5-28 15:37:00 | 显示全部楼层
记住要改MSS

/ ip firewall mangle
add chain=forward out-interface=pppoe-out1 protocol=tcp tcp-flags=syn \
  action=change-mss new-mss=1400 comment="" disabled=no

/ ip firewall nat
add chain=srcnat src-address=192.168.1.0/24 action=masquerade comment="" \
  disabled=no
这个不 是 太明白!能 详细解说下吗?
routeros
回复

使用道具 举报

发表于 2008-5-28 15:40:37 | 显示全部楼层
/ ip firewall nat
add chain=srcnat src-address=192.168.1.0/24 action=masquerade comment="" \
  disabled=no
这个是共享上网SCR=192.168.1.0/24是内网的地址网段
routeros
回复

使用道具 举报

发表于 2008-5-28 15:42:05 | 显示全部楼层
/ ip firewall mangle
add chain=forward out-interface=pppoe-out1 protocol=tcp tcp-flags=syn \
  action=change-mss new-mss=1400 comment="" disabled=no
这里业可以写成这样
/ ip firewall mangle
add chain=forward protocol=tcp tcp-flags=syn \
  action=change-mss new-mss=1440 comment="" disabled=no
ROS3.9的版本是自动加上的
routeros
回复

使用道具 举报

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

本版积分规则

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

GMT+8, 2024-9-29 01:21 , Processed in 0.061773 second(s), 6 queries , Gzip On, Redis On.

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

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