DNS

From Bibliotheca Anonoma
Revision as of 04:00, 21 January 2020 by Antonizoon (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Since IP Addresses are difficult to remember, and often change weekly, it is strongly recommended to use a Dynamic DNS to access your server instead of a bare IP Address.

DuckDNS

DuckDNS is the preferred free DynamicDNS system, because it is well documented, easy to use, and free. But any other Dynamic DNS service could work. You can even host a basic website this way (though too much traffic might be in violation of your home broadband policy).

Follow the installation guide here.

Namecheap

ddclient

/etc/ddclient.conf

# Configuration file for ddclient generated by debconf
#
# /etc/ddclient.conf

daemon=300
pid=/var/run/ddclient.pid

ssl=yes
use=web, web=dynamicdns.park-your-domain.com/getip
protocol=namecheap
server=dynamicdns.park-your-domain.com    # don't change this

login=example.com                         # your domain here
password=d5af754af8fc8b0                  # dynamic DNS password
@                                         # domain or subdomain

This will set an example.com domain. You can also set a subdomain by replacing the @ with the subdomain: mail for mail.example.com, or mail,bibanon for bibanon.example.com/code> in addition.

Then, edit /etc/default/ddclient, and set these options in the config file :

# cannot be enabled at the same time as the daemon
run_ipup="false"

# enable daemon at boot
run_daemon="true"
  1. Ensure that the configuration is working:

    sudo ddclient -daemon=0 -debug -verbose -noquiet
  2. Start the ddclient service.

    sudo systemctl restart ddclient
  3. Check whether the ddclient service worked. If not, edit ddclient.

    sudo systemctl status ddclient
  4. Enable the ddclient service at boot:

    sudo systemctl enable ddclient