DNS: Difference between revisions
Antonizoon (talk | contribs) (Created page with "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. ==...") |
Antonizoon (talk | contribs) No edit summary |
||
Line 25: | Line 25: | ||
server=dynamicdns.park-your-domain.com # don't change this | server=dynamicdns.park-your-domain.com # don't change this | ||
login= | login=example.com # your domain here | ||
password=d5af754af8fc8b0 # dynamic DNS password | password=d5af754af8fc8b0 # dynamic DNS password | ||
@ # domain or subdomain</pre> | @ # domain or subdomain</pre> | ||
This will set an <code> | This will set an <code>example.com</code> domain. You can also set a subdomain by replacing the <code>@</code> with the subdomain: <code>mail</code> for <code>mail.example.com</code>, or <code>mail,bibanon</code> for <code>bibanon.example.com/code> in addition. | ||
Then, edit <code>/etc/default/ddclient</code>, and set these options in the config file : | Then, edit <code>/etc/default/ddclient</code>, and set these options in the config file : |
Latest revision as of 04:00, 21 January 2020
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[edit]
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[edit]
ddclient[edit]
/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"
Ensure that the configuration is working:
sudo ddclient -daemon=0 -debug -verbose -noquiet
Start the ddclient
service.
sudo systemctl restart ddclient
Check whether the ddclient
service worked. If not, edit ddclient.
sudo systemctl status ddclient
Enable the ddclient
service at boot:
sudo systemctl enable ddclient