Overview
This guide explains how to force the Unifi Controller to update DDNS using built-in configurations. I encountered this issue during my initial setup of DDNS and several times after rebooting or editing A records.
Prerequisites
Knowledge of the following:
- DDNS
- Linux structure
- Domain management
- A records
- Unifi Controller
- SSH
Disclaimer
This guide is based on research, and I recommend exercising caution when working with the Unifi Controller.
SSH (Secure Shell) is a protocol used to securely access and manage network devices. To begin, open your terminal or command prompt and use the following command to SSH into the Unifi Controller:
ssh username@controller-ip-address
Replace username with your actual username and controller-ip-address with the IP address of your Unifi Controller. You will be prompted to enter your password.
Once logged in, you will have access to the command line interface of the Unifi Controller.
cd /run
ls
It should look something like this:
The configuration file should look something like this: ddns-eth9-inadyn.conf The "eth9" can vary.
Use the following command to force the configurations in your DDNS settings
inadyn -n -1 --force -f /run/"Your-Config-File"
Replace "Your-Config-File" with the configuration file you located in Step 2. Based on the picture provided above the command would look like this: "inadyn -n -1 --force -f /run/ddns-eth9-inadyn.conf"
It should look something like this:
The output should look something like this:
inadyn[55425]: In-a-dyn version 2.12.0 **(Version can be different)** -- Dynamic DNS update client.
inadyn[55425]: Update forced for alias **(Hostname)**, new IP# **(Your-WAN-IP)**
inadyn[55425]: Updating cache for **(Hostname)**
If you are running into issues, then open a second ssh terminal and run this commmand in the new terminal
tail -n 1000 /var/log/messages | grep dyn
This will give a line-by-line view of potential errors for the last 1000 entries. The command running will look something like this:
If you are still running into issue. You can run this debug command:
/usr/sbin/inadyn -n -s -C -f /run/iadyn.conf -1 -1 debug --force
In this guide, you learned how to force the Unifi Controller to update DDNS using built-in configurations. By following the steps outlined, you should be able to troubleshoot common issues related to DDNS updates, ensuring your domain remains linked to your current IP address.
Always remember to exercise caution when making changes to your Unifi Controller settings, and feel free to consult the official documentation or community forums for additional support. With the right knowledge and tools, managing your DDNS can be straightforward and effective.
If you have further questions or need assistance, don’t hesitate to reach out to the community or consult professional support.