文件名称:CGO
介绍说明--下载内容均来自于网络,请自行研究使用
多条ADSL 相同网关 ROS 的解决办法:
脚本如下: 由于时间比较赶,没有对语句进行简化。
:if ([/in pppoe-c get [find name=ADSL-WAN2] running]=true) do {
:set NewID2 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN2] pref-src]
:set OldIP2 [/ip route get [find comment=2] gateway]
:if ($NewID2 != $OldIP2 ) do {
/ip address set [find comment=2] address=$NewID2 network=$NewID2 broadcast=$NewID2
/ip route set [find comment=2] gateway=$NewID2}
}
:if ([/in pppoe-c get [find name=ADSL-WAN3] running]=true) do {
:set NewID3 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN3] pref-src]
:set OldIP3 [/ip route get [find comment=3] gateway]
:if ($NewID3 != $OldIP3 ) do {
/ip address set [find comment=3] address=$NewID3 network=$NewID3 broadcast=$NewID3
/ip route set [find comment=3] gateway=$NewID3}
-多条ADSL 相同网关 ROS 的图文解决办法:
脚本如下: 由于时间比较赶,没有对语句进行简化。
:if ([/in pppoe-c get [find name=ADSL-WAN2] running]=true) do {
:set NewID2 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN2] pref-src]
:set OldIP2 [/ip route get [find comment=2] gateway]
:if ($NewID2 != $OldIP2 ) do {
/ip address set [find comment=2] address=$NewID2 network=$NewID2 broadcast=$NewID2
/ip route set [find comment=2] gateway=$NewID2}
}
:if ([/in pppoe-c get [find name=ADSL-WAN3] running]=true) do {
:set NewID3 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN3] pref-src]
:set OldIP3 [/ip route get [find comment=3] gateway]
:if ($NewID3 != $OldIP3 ) do {
/ip address set [find comment=3] address=$NewID3 network=$NewID3 broadcast=$NewID3
/ip route set [find comment=3] gateway=$NewID3}
脚本如下: 由于时间比较赶,没有对语句进行简化。
:if ([/in pppoe-c get [find name=ADSL-WAN2] running]=true) do {
:set NewID2 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN2] pref-src]
:set OldIP2 [/ip route get [find comment=2] gateway]
:if ($NewID2 != $OldIP2 ) do {
/ip address set [find comment=2] address=$NewID2 network=$NewID2 broadcast=$NewID2
/ip route set [find comment=2] gateway=$NewID2}
}
:if ([/in pppoe-c get [find name=ADSL-WAN3] running]=true) do {
:set NewID3 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN3] pref-src]
:set OldIP3 [/ip route get [find comment=3] gateway]
:if ($NewID3 != $OldIP3 ) do {
/ip address set [find comment=3] address=$NewID3 network=$NewID3 broadcast=$NewID3
/ip route set [find comment=3] gateway=$NewID3}
-多条ADSL 相同网关 ROS 的图文解决办法:
脚本如下: 由于时间比较赶,没有对语句进行简化。
:if ([/in pppoe-c get [find name=ADSL-WAN2] running]=true) do {
:set NewID2 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN2] pref-src]
:set OldIP2 [/ip route get [find comment=2] gateway]
:if ($NewID2 != $OldIP2 ) do {
/ip address set [find comment=2] address=$NewID2 network=$NewID2 broadcast=$NewID2
/ip route set [find comment=2] gateway=$NewID2}
}
:if ([/in pppoe-c get [find name=ADSL-WAN3] running]=true) do {
:set NewID3 [/ip route get [/ip route find dst-address=59.41.154.1/32 interface=ADSL-WAN3] pref-src]
:set OldIP3 [/ip route get [find comment=3] gateway]
:if ($NewID3 != $OldIP3 ) do {
/ip address set [find comment=3] address=$NewID3 network=$NewID3 broadcast=$NewID3
/ip route set [find comment=3] gateway=$NewID3}
相关搜索: ros
(系统自动生成,下载前可以参看下载内容)
下载文件列表
CGO.doc