parceiro quando você aciona o script verifique no log de registro se aparace DNS NO CHANGE.
Se isto ocorrer, favor verificar seguintes itens.
modem com nat ?
algum router após modem?
Versão Imprimível
parceiro quando você aciona o script verifique no log de registro se aparace DNS NO CHANGE.
Se isto ocorrer, favor verificar seguintes itens.
modem com nat ?
algum router após modem?
Substitua estas linhas:
:if ([/interface get $inetinterface value-name=running]) do={
# Get the current IP on the interface
:local currentIP [/ip address get [find interface="$inetinterface" disabled=no] address]
# Strip the net mask off the IP address
:for i from=( [:len $currentIP] - 1) to=0 do={
:if ( [pick $currentIP $i] = "/") do={
:set currentIP [pick $currentIP 0 $i]
}
}
Por estas:
# get the current IP address from the internet (in case of double-nat)
/tool fetch mode=http address="checkip.dyndns.org" src-path="/" dst-path="/dyndns.checkip.html"
:local result [/file get dyndns.checkip.html contents]
# parse the current IP result
:local resultLen [:len $result]
:local startLoc [:find $result ": " -1]
:set startLoc ($startLoc + 2)
:local endLoc [:find $result "</body>" -1]
:local currentIP [pick $result $startLoc $endLoc]
# :log info "UpdateDynDNS: currentIP = $currentIP"
No seu script, está checando o ip da Speedy, que se estiver atras de um modem roteado nao vai mudar. So funcionaria se o modem estivesse em bridge.
Neste outro caso, funciona de qualquer jeito, pois utiliza um site externo para pegar o ip da conexao.
Se quiser ver seu ip atual, basta colocar no navegador:
http://checkip.dyndns.org/