河东软件站

电脑版
提示:原网页已由神马搜索转码, 内容由www.pc0359.cn提供.
所在位置:首页 > 网吧软件 > ROS软路由> ADSL在网吧的应用(ADSL动态网关脚本和光纤零点自动切换)

ADSL在网吧的应用(ADSL动态网关脚本和光纤零点自动切换)

 
  • 软件大小:202 KB
  • 更新日期:2009-06-19
  • 软件语言:简体中文
  • 软件类别:ROS软路由
  • 软件授权:共享软件
  • 软件官网:未知
  • 适用平台:Win2003, WinXP, Win2000, NT, WinME
  • 软件厂商:
10.0
软件评分

本地下载

软件介绍人气软件相关文章网友评论下载地址

为您推荐:ROS软路由

因为在当地的ADSL是动态网关,而且光纤每天早上到凌晨12点断线,所以配合一条家用的ADSL线路来通宵营运,我简单设计了一个方案,每15秒自动检查一次ADSL网关是否与路由表里的符合,做了一个NETWATCH监控光纤线路是否掉线,如果掉线了就切换成ADSL的网关.

有不足的地方希望网友们斧正,仅此抛砖引玉.

动态网关脚本:


:global adsl "ADSL连接的名字"
:global new-ip [ /ip address get [/ip address find broa=0.0.0.0 int=$adsl] network ]
:global old-ip [ /ip route get [/ip route find comm="adsl"] gateway ]
:if ($new-ip != $old-ip) do={
    :log info [/ip route set [/ip route find comm="adsl"] gateway=$new-ip]
    :log info "〖ADSL网关修改完毕〗"
  }

cableup脚本:
/ip route set [/ip route find comm="cable"] disable=no
/ip route set [/ip route find comm="adsl"] disable=yes

cabledown脚本:
/ip route set [/ip route find comm="cable"] disable=yes
/ip route set [/ip route find comm="adsl"] disable=no

以上标记的红字均可根据你的实际情况进行替换.

光纤和ADSL实现线路切换的原理是,当光纤掉线以后,自动禁用光纤的路由,激活ADSL路由(动态网关脚本会15秒自动检测).当光纤恢复以后,则规则反之执行.

下载地址

网友评论0

您的评论需要经过审核才能显示