A Dynamic DNS client for Windows
|Hello.
Here’s a link to ddclient.exe, a dynamic DNS client for Windows, to go with the dynamic DNS server that I’ve posted about as part of a 3-part series of posts (Part 1, Part 2).
Click on the big green button with an arrow on it, download the installer, save it on a machine somewhere that you wish to refer to by a DNS name, run it, click the Next button a few times, enter the configuration values in the text fields shown below, click Next a few more times, and you should be right as rain.
It’s essentially a PAR‘ed up version of a slightly modified ddclient, packaged as a Windows service with an NSIS wrapper around it so that you can install/uninstall it a bit easier.
The only modifications I’ve made to ddclient itself is to Windows™-ify it a bit more (when running as a service, it stores the ddclient.cache and logfiles in the local application data folder)
This should hopefully save you the trouble of installing and configuring perl / ddclient on each Windows machine that you wish to perform DNS updates for.
It should all be relatively simple to use, but here are some screenshots:
Since the original ddclient looks like it might be GPL’ed, I’ll pop the sourcecode up here at some stage. In the meantime, if you want the sourcecode, let me know and I’ll email it to you. Here it is on github.
ddclient service Windows account
When you install using the NSIS installer, you will be prompted which Windows user you wish to run the ddclient service as (see the second screenshot above). The options are:
- Local System: Completely trusted account, moreso than the administrator account. There is nothing on a single box that this account can not do and it has the right to access the network as the machine.
- Network Service (recommended): Limited service account that is meant to run standard least-privileged services. This account is far more limited than Local System (or even Administrator) but still has the right to access the network as the machine.
- Custom account: If you like, you can choose an existing account, which can be a standard user account or one you have created if specifically to run the ddclient application.
You probably just want to use the Network Service account.
Log file location
If the ddclient application doesn’t appear to be working, then you probably want to check the contents of the log file first. The location of the logs should be in the service account’s local Application Data folder, and is called ddclient.log
On Windows 10, the logs can be found at:
- C:\windows\ServiceProfiles\LocalService\AppData\Local\ddclient.log
- C:\windows\ServiceProfiles\NetworkService\AppData\Local\ddclient.log
- C:\Users\username\AppData\Local\ddclient.log
Silent installation
The installer (as of 1.1.0) now supports silent installation; that is, you can specify on the command line the details that are requested during install, and the client (and service) will be installed without displaying the graphical user interface.
You can get the list of parameters by typing ddclient-1.8.0 /?
at the C:\ prompt, which will display something similar to the following:
An example command-line would look something like:
C:\installer>ddclient-1.8.0 /S /HOSTNAME=movingtarget.example.com /DDSERVER=dyndns.namingwords.com /DDCONNECTION=HTTP /DDPROTOCOL=dyndns2 /DDUSERNAME=scott /DDPASSWORD=tiger /SERVICEASNETWORKUSER
which would allow you to refer to the current machine as movingtarget.example.com
, and access any publicly accessible ports on that machine from The Cloud, i.e. wherever you happen to be on the internet.
Some things on my TODO list include
scriptable (silent) installations, and- fixing a bug I’m seeing on Windows 7 when using a custom Windows account to run the service (as a workaround, install it using the Network Service account and then change the account yourself in Control Panel -> Administrative Tools -> Services )
Update 21/8/2013: Updated to version 1.0.1 of the installer/uninstaller (logs in application data, kills process during service removal), added screenshots.
Update 25/8/2013: Updated to version 1.1.0 of the installer/uninstaller (silent install; software is now licensed under the ‘BSD Simplified’ license), updated screenshots/text.
Update 29/6/2014: Updated to version 1.2.0 of the installer/installer (SSL support, protocol selection support, added Digest::SHA1 to the list of included perl packages as requested, removed ddclient.conf permission checks as requested)
Update 20/5/2015: Updated to version 1.4.0 of the installer/installer (ddclient 3.8.2 changes including changeip protocol, GNU licence, now hosted on github)
Update 26/6/2016: Updated to version 1.5.0 of the installer/installer (ddclient 3.8.3 changes including nsupdate protocol, cloudflare protocol, googledomains protocol and the duckdns protocol).
Update 25/7/2021: Updated to version 1.6.0 of the installer/installer (ddclient 3.9.1 changes including dinahosting, dnsmadeeasy, dondominio, freemyip, gandi, nfsn, ovh, woima, yandex, dnsexit). Now compiles on 64-bit Windows 10 using strawberry perl.
Update 7/11/2021: Updated to version 1.7.0 of the installer/installer to fix a missing DLL issue – see https://github.com/randomnoun/ddclient-nsis/issues/6
Update 27/4/2022: Updated to version 1.8.0 of the installer/installer to include ‘JSON:PP’ package ( for cloudflare / gandi ) – see https://github.com/randomnoun/ddclient-nsis/issues/6
It’s also now on github:
Is there an equivalent for “use=if, if=eth0” on windows?
Hi franz. Because the service is still running the original perl ddclient.pl under the hood, you should be able to use all available ddclient.conf parameters (including use and if).
Just update the ddclient.conf file with those settings. It’s stored in the ddclient.conf file in the installation directory (Usually C:Program Filesddclientddclient.conf)
Any idea how to get the interface names on Windows? I’d like to use this for a VPN interface.
Is it possible to transmit the IP via SSL? If so – do I need something like OpenSSL additionally installed or does this client use libraries which Windows 7 already offers?
I’m using SSL to update the IP.
Just add this in your ddclient.conf
ssl=yes
SSL is now supported through the installer in v1.2.0
Thank you for this package, I could not find a good generic dynamic dns updater for windows and I was about to do a simplified version of your work to be able to use ddclient in windows in a more integrated way, so thank you 🙂
This is a great wrapper .. but it’s missing one small feature. In order to use the freedns.afraid.org, the installation has to include the Perl module Digest::SHA1. Is there any chance this could be packaged into the binary?
Digest::SHA1 is now included in v1.2.0
This works great!!
Could you make an option for using SSL or not in the installation wizard? The SSL is required in my case. And sure, I can edit the config file, but that’s not very user friendly.
Keep up the good work!
Great idea–thanks for the work on this. I have updates to NameCheap working with some .conf modifications. However under XP with NTFS, the following warnings repeat in the log file, apparently on every update–concerned that the log may expand too much–is it trimmed occasionally?
WARNING: file C:Program Filesddclientddclient.conf: file C:Program Filesddclientddclient.conf must be accessible only by its owner.
WARNING: file C:Documents and SettingsNetworkServiceLocal SettingsApplication Dataddclient.cache: file C:Documents and SettingsNetworkServiceLocal SettingsApplication Dataddclient.cache must be accessible only by its owner (fixed).
Hi Mark. The .conf accessibility checks have been removed from v1.2.0
Well it looks like the ddclient under Windows wasn’t updating regularly after all, even though two instances of ddclient.exe were running in Task Manager. Also, I discovered that ddclient does not support one of my providers, DNS Made Easy. I wound up writing PowerShell scripts to do the updates.
I’m not sure which protocol DNS Made Easy provide, but the full set of protocols implemented in the perl ddclient can now be selected in the NSIS installer in v1.2.0.
Works perfect!
The only thing to complain is memory usage (Win7 prof. and Win SBS 2011).
I have two ddclient.exe in the taskmanager, one that describes himself as “A dynamic DNS client” with ~500 kB – which is fine.
But there is another ddclient.exe in the taskmanager without description, an that one uses ~ 16 MB.
That’s more than my downloadmanger (pyLoad), twice the memory usage of my torrentclient (µtorrent) – wich both include WebUIs – and 8 times the memory usage of my FTP-Server!
Ihmo a bit heavy for an (relativley simple) DNS-Updater.
I believe the current version of ddclient supports DNSEXIT (dnsexit.com). Any chance you could update to include this?
Thanks
cool tool
small, unvisible (if somebody want it), effective
Thanks to down under from Germany
Thanks a lot.
Do you support ssl=yes?
Hi eltorio.
If you change the Connection type to HTTPS in the installer, this is equivalent to setting ‘ssl=yes’
Hi, would it be possible to include ipv6 support? The new ddclient Linux Version 3.8.2 has a new Variable “usev6”. So you are able to update ipv4 and ipv6. Would be nice.
For anyone interested in using this client with Google Domains (domains.google.com), the stock installation won’t work, I *think* because it attempts to use the non-existent domains.google.com/nic/checkip.html for IP lookup.
If you simply don’t specify an IP the Google Domains service uses the IP of the incoming request, which works fine for my needs, so I got it working by manually tweaking ddclient.conf as follows:
# ddclient.conf
daemon=5m
protocol=dyndns2
use=web
server=domains.google.com
ssl=yes
login=
password=
..
Oh, thanks a lot!
I have struggled my entire day to solve the problem and finally found your reply!
Thanks from me as well!
Hi!
The ‘web’ value in the default configuration is wrong for dnsdynamic service.
After fresh install this is: “www.dnsdynamic.org/nic/checkip.html”.
This address responses “nohost” for me all time.
I changed this to http://myip.dnsdynamic.org/ and ddlient is working. 🙂
Br:
d
Works great w/ Google domains if you choose a different server. myip.dnsdynamic.org works a treat. Thanks for making this!
When I run the exe in the command line from “C:Program Files (x86)ddclient” I get the error “WARNING: file /etc/ddclient/ddclient.conf: Cannot open file ‘/etc/ddclient/ddclient.conf’. (No such file or directory)”. It’s as if the code still thinks it is on a linux machine. The errory is written twice to the console. Any idea why?
Hi Rory
Try using the following command-line switches:
Replacing username above with your Windows username.
(This is the command-line that’s used by the ‘Start ddclient console’ start menu shortcut.
It looks like this very convenient tool was updated on May 20 2015 using version 3.8.2 of ddclient. Unfortunately this was just a few days before ddclient itself was updated to version 3.8.3 on May 28. One feature that is in 3.8.3 that would be nice to have is support for the “googledomains” protocol. Google Domains can be made to work using the dyndns2 protocol, but it would be nice to have Google’s own protocol supported too.
ddclient 3.8.3 is now packaged as part of v1.5.0 of the installer… sorry about the delay 🙂
Hi knoxg
With version 1.4.0 I have a problem.
Whenever I restart the service another instance is started. So the previous process doesn’t get killed and just another one is started. This didn’t occur in the previous versions. Anyway thanks for the nice piece of software making my life more easy.
Regards
Obs
I see the same question was asked here before. But… how to specify an interface in Windows? What is eth0 equivalent?
Thanks!
Hi, if i start ddclient via task sheduler no logfile is to be found! Whereas the .cache file is generated correctly under the appdata of the current user running the task …. the logfile is not.
When i run it as a service, it is generated. But not updated when run as a user again.
So where is my logfile?
Thx
When I try to edit the .conf I get an “Access is denied” message.
@Sammy: Long time ago, but i someone have the same question:
Stop ddclient service, open ddclient.conf as adminstrator and you will able to edit and save your changes.
@knoxg – Thanks a lot for providing this tool
Run notepad as admin and open the file from notepad
Hi,
Thanks the adaption looks great.
Nevertheless I get an issue with OVH provider and the dyndns2 protocol.
It looks like an update of the original DDCLIENT solved the problem.
Do you plane to update this very usefull windows adaptation ?
Thanks anyway for the great job
Fabrice
Will there ever be an update to allow multiple domain name updates with different providers?
Trying to get this running with google domains. I have a couple of things going on I think:
1) Not sure if I am understanding all of the fields in the installer correctly. Should client host name be mysubdomain.domain.com and the server be “domains.google.com”? Or is the server the subdomain that I am trying to create the DDNS record for?
2) In trying several different config files I also tried to run the exe from command line and got the issue where it was looking for the config file as if it were in a unix environment. I tried running with the modifiers listed in a previous post but it just hangs there. No errors, no new prompt, it just sits there. No cache file was ever created in the directory referenced in the modifiers.
So I’m not really sure what I’m doing wrong here. Running 1.5.0. I tried the installer config as dydns2 as well as googledomains for protocol. Same results.
In the \Windows\Service Profiles\App Data\Local\ddclient.log file I do get an error that ends with “Invalid Value for keyword ‘ip’ = ”” referring to the cache file in the same directory.
I must be missing something here.
I have a domain that is a special ending. Like .tech .fun, .whatever… I keep getting errors ‘zone=’ is an invalid fully qualified host name. I’m assuming that this problem is because of the weird domain ending.
It looks like for the weird TLDs, you need an extra line in the ddclient.conf file:
“zone=”
See here:
https://github.com/ddclient/ddclient/issues/82
However, it seems that simply adding this bit to the ddclient.conf does not work in our case — perhaps the zone is not being read, as I still get the same answer?
This recently has stopped working with nsupdate.info when SSL is enabled, on several computers (all that I’ve looked at so far). I believe it is something they changed on their end. If I set to non-ssl it works normally. It looks like it doesn’t like the TLS version they now require, perhaps. Thanks.
Can DD client handle more than 1 entry?
I want to move my domains from noip.com which I’ve used for years, to google domains.
However I have a problem moving these domains to google in that I found that my ZyWall 110 has a maximum of 10 entries that can be configured for DDNS.
I’ve configured 10 google domains successfully using their DDNS service (albeit took a while as im not technical) however have hit a roadblock in that I’ve found the 10 entry limit (Zyxel support says this cant be changed).
I tried googling to find a workaround solution most suggested scripts etc beyond my technical skills but found no “clients” that can update DDNS until I found your DDClient solution.
I went to install the app but it appears that it will only update for a single entry?
Can you run multiple domains on google with this client?
Does not work anymore. SSL error. Maybe needs an update.
yup, same here
Can you please update the build to latest ddclient 3.9.1 version, please?
Thank you very much.
The latest release (1.6.0) is now built on ddclient 3.9.1.
It’s now a 64-bit executable so let me know if anything breaks
I’ve just installed 1.6.0… It starts the services Ok, but no log available in usual path, so I can’t say if it’s working or not… Any idea?
I come from and old 1.2.0 which created log file but had other problems, thats why I want to move.
Hello. The same issues as JL Montero
Installed 1.6.0 It starts the services Ok, but no log available in usual path, so I can’t say if it’s working or not.
Windows ver. 20H2 Professional
From version 1.6.0 onwards I’m only building / testing on Windows 10, but I’ve put the older versions ( that were built on XP ) in an archive folder in github here: https://github.com/randomnoun/ddclient-nsis/tree/master/dist/archive
When I use “ssl=yes” I get the following errors and the IP doesn’t update:
WARNING: cannot connect to svc.joker.com:443 socket: IO::Socket::SSL: SSL connect attempt failed with unknown error error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version IO::Socket::INET configuration failed error:00000000:lib(0):func(0):reason(0)
FAILED: updating : Could not connect to svc.joker.com/nic/update?.
If I change to “ssl=no” then it updates fine, though my credentials are potentially exposed. I’m making a wild guess that this has something to do with older versions of TLS being deprecated.
Can you try on the latest release (1.6.0) and see if this works any better ?
I am seeing similar errors with 1.8.0 ( which disappear without SSL)
WARNING: cannot connect to dyn.dns.he.net:443 socket: No such host is known. IO::Socket::IP configuration failed
FAILED: updating XXXXXXX: Could not connect to dyn.dns.he.net.
WARNING: cannot connect to ipv4.checkip.dns.he.net:443 socket: No such host is known. IO::Socket::IP configuration failed
WARNING: found neither IPv4 nor IPv6 address
Use of uninitialized value $ip in string at script/ddclient line 3589.
the error seems to indicate a name resolution error . but removing the ssl=yes in the config file makes the error go away.
Hi, when i try to start the console (on Win10 Pro x64) i get:
“Can’t load ‘C:\Users\T251E~1.MER\AppData\Local\Temp\par-742e6d65726b656c\cache-f6d413a946a68811a62a958c4938e0cf83468dc3\ed365286.xs.dll’ for module Net::SSLeay: load_file:Das angegebene Modul wurde nicht gefunden at /DynaLoader.pm line 193.
at /PAR/Heavy.pm line 95.
Compilation failed in require at C:\Users\T251E~1.MER\AppData\Local\Temp\par-742e6d65726b656c\cache-f6d413a946a68811a62a958c4938e0cf83468dc3\inc\lib/IO/Socket/SSL.pm line 19.
BEGIN failed–compilation aborted at C:\Users\T251E~1.MER\AppData\Local\Temp\par-742e6d65726b656c\cache-f6d413a946a68811a62a958c4938e0cf83468dc3\inc\lib/IO/Socket/SSL.pm line 19.
Compilation failed in require at script/ddclient line 34.
BEGIN failed–compilation aborted at script/ddclient line 34.”
ddclient is v1.6.0
Any suggestions?
Thanks a lot
tm-107
Yep think that’s the same issue reported here https://github.com/randomnoun/ddclient-nsis/issues/6
which should be fixed in the latest 1.7.0 installer
any idea how to set more than 1 host in windows?
In the ddclient source it states that
So you could try editting the ddclient.conf file and adding multiple hosts, separated by commas
Please help me. I tried to make it work on my windows pc, I can’t get it to work. I can access and login to the strato URL from my web-browser just fine. My configuration is:
=======================
# ddclient.conf
#
daemon=5m
use=web
web=https://dyndns.strato.com/nic/update/nic/checkip.html
server=https://dyndns.strato.com/nic/update
protocol=dyndns2 login=cloudcroft.nl, password=************* home.cloudcroft.nl
ssl=yes
=======================
The ddclient.log says:
=======================
WARNING: found neither IPv4 nor IPv6 address
WARNING: cannot connect to https:443 socket: Host is onbekend. IO::Socket::IP configuration failed
FAILED: updating home.cloudcroft.nl: Could not connect to https://dyndns.strato.com/nic/update.