Community discussions

MikroTik App
 
szalkerous
newbie
Topic Author
Posts: 36
Joined: Thu Jan 21, 2016 2:30 am
Location: NH, USA

Updated ChangeIP DDNS script for ROS 7.xx

Wed Jun 21, 2023 5:15 am

Hello all,

It seems the RouterOS 7.xx dns-update command is no longer working with the ChangeIP dynamic DNS service, or at least I couldn't get it to work.

Based on some other suggestions here I have modified the "official" ChangeIP script. This modified method uses the fetch command to HTTPS/GET the DDNS API. I have verified on my account it shows as "Mikrotik/7.x Fetch" and updates successfully.

I'm not a RouterOS scripting guru, so any feedback is welcomed.
changeip.zip
You do not have the required permissions to view the files attached to this post.
 
User avatar
rextended
Forum Guru
Forum Guru
Posts: 12632
Joined: Tue Feb 25, 2014 12:49 pm
Location: Italy
Contact:

Re: Updated ChangeIP DDNS script for ROS 7.xx

Wed Jun 21, 2023 10:40 am

There are hundreds of other dynamic DNS update scripts, even better written, and some even worse.
The only thing that changes between all is how they were written and the URL of the GET, but then in the end it's always the same story...
 
nero9
just joined
Posts: 1
Joined: Wed Jan 31, 2024 6:33 pm

Re: Updated ChangeIP DDNS script for ROS 7.xx

Sat Feb 03, 2024 2:15 pm

Not work...

Log: DDNS: No ip address present on WAN, please check.
 
helco
just joined
Posts: 1
Joined: Fri Feb 03, 2023 1:29 pm

Re: Updated ChangeIP DDNS script for ROS 7.xx

Sun May 19, 2024 7:28 am

After replacing these commands
:do {
   :global ddnssystem ("mt-" . [/system package get [/system package find name=routeros] version] )
} on-error={ :log error "DDNS: Could not retrieve system version info"};

:do {
   :local ddnsip [ /ip dhcp-client get [/ip dhcp-client find where interface=$ddnsinterface] address ]
} on-error={ :log error "DDNS: could not retrieve IP address from DDNS interface"};
with these
:global ddnssystem
:do {
   :set $ddnssystem ("mt-" . [ /system package get [/system package find name=routeros] version] );
} on-error={ :log error "DDNS: Could not retrieve system version info"};


:local ddnsip
:do {
        :set $ddnsip [/ip dhcp-client get [/ip dhcp-client find where interface=$ddnsinterface] address];
} on-error={ :log error "DDNS: could not retrieve IP address from DDNS interface"};
script working again.
 
User avatar
rafie
just joined
Posts: 3
Joined: Wed Jun 20, 2018 1:00 am

Re: Updated ChangeIP DDNS script for ROS 7.xx

Thu Jul 25, 2024 9:01 pm

Hello,
I'm trying to run a dddns updater using no-ip.
i'm trying to configure your script on my Mikrotik routeur.

As i'm still a newbee, can you help me in the script config what to put beside "local ddnsinterface" in this line(23):
":local ddnsinterface "INTERFACENAME""
Thank you in advance