I edited and got the v2.9 script for Dynamic DNS running on V3.0.
Here is my script
:log info "DDNS: Begin"
:global ddnsuser "YOURUSERNAME"
:global ddnspass "YOURPASSWORD"
:global ddnshost "*1"
:global ddnsinterface "YOUREXACTINTERFACENAME"
:global ddnsip [ /ip address get [/ip address find interface=$ddnsinterface] address ]
:if ([ :typeof ddnslastip ] = nil ) do={ :global ddnslastip 0.0.0.0/0 }
: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 [ /tool dns-update name=$ddnshost address=[:pick $ddnsip 0 [:find $ddnsip "/"] ] key-name=$ddnsuser key=$ddnspass ]
:global ddnslastip $ddnsip
} else={
:log info "DDNS: No change"
}
}
:log info "DDNS: End"
Hope it works for you