Page 1 of 1

Changed to ChangeIP but need to keep Dyndns name!

Posted: Sun Mar 15, 2009 10:49 am
by markrudling
Hi

I have got the changeip script working, so all good. however i now need to keep my dyndns name, as to many clients are already configured for that name. Im not running http services, so i need all ports to be directly redirected. Any ideas?

Also, is it possible to mod the script to work with a specific pppoe connection, my MT needs to dial 4

Thanks
Mark

Re: Changed to ChangeIP but need to keep Dyndns name!

Posted: Sun Mar 15, 2009 7:14 pm
by changeip
you can update your dyndns hostname to become a cname of the changeip one. that way it is just an alias.

we can modify that script to work on a particular interface specifically... email us directly and we will work with you to get what you need. support at changeip dot com.

Sam

Re: Changed to ChangeIP but need to keep Dyndns name!

Posted: Wed Apr 01, 2009 8:27 pm
by knects
Are you saying that you can modify this so that it will update the address of an interface that I specify? I am using ECMP routing on 2 PPPoE connections. One is static and has dns set for it. The 2nd connection changes anytime the interface drops. I would like to setup a changip host and have the script update the host with the DHCP address from the 2nd wan link.

Re: Changed to ChangeIP but need to keep Dyndns name!

Posted: Thu Apr 02, 2009 4:19 pm
by hilton
Use this script;
:global ddnsuser "your_account_name"
:global ddnspass "your_account_password"
:global ddnshost "your_changeip_ddns_name"
:global ddnsip
:global ddnslastip [:tostr [:resolve $ddnshost] ]
:if ([ :typeof $ddnslastip ] = nil ) do={ :global ddnslastip "0" }
:global ddnsinterface "your_mikrotik_interface_name"
:global ddnssystem ("mt-" . [/system package get system version] )

:local int

:local ddnsipfn [ /ip address get [/ip address find interface=$ddnsinterface ] address ]
:global ddnsip [:pick $ddnsipfn 0 [:find $ddnsipfn "/"]]

:if ([ :typeof $ddnsip ] = nil ) do={
:log info ("DDNS: No ip address present on " . $ddnsinterface . ", please check.")
} else={

:if ($ddnsip != $ddnslastip) do={

:log info "DDNS: Sending UPDATE!"
:log info [ :put [/tool dns-update name=$ddnshost address=$ddnsip key-name=$ddnsuser key=$ddnspass ] ]
:global ddnslastip $ddnsip

} else={
:log info "DDNS: No update required."
}

}