LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 02-17-2020, 06:59 PM   #1
wh33t
Member
 
Registered: Oct 2003
Location: Canada
Posts: 922

Rep: Reputation: 61
Is it possible to use dynamic dns resolution with a top level domain?


I'm pretty sure this is possible but I can't quite recall how to do it. Does it involved signing up with a service somewhere and running a cron job on a single system behind my home router?

Just to clarify, I want to map a domain name I own to my home IP address, which may change every few months. I am unable to get a static IP.

Any tips greatly appreciated. Thank you.

Last edited by wh33t; 02-17-2020 at 07:00 PM.
 
Old 02-18-2020, 12:19 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,695

Rep: Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894
There are several dynamic IP DNS sites, noip.com, dynu.com or DuckDNS are a few. They typically have a client program that runs in the background to update their servers when your IP changes. Newer router models may have a built in dyndns client so you may not need to install anything on the computer itself.

The sites posted are free but using your own domain name might cost a fee.
 
1 members found this post helpful.
Old 02-18-2020, 01:18 PM   #3
wh33t
Member
 
Registered: Oct 2003
Location: Canada
Posts: 922

Original Poster
Rep: Reputation: 61
Quote:
Originally Posted by michaelk View Post
There are several dynamic IP DNS sites, noip.com, dynu.com or DuckDNS are a few. They typically have a client program that runs in the background to update their servers when your IP changes. Newer router models may have a built in dyndns client so you may not need to install anything on the computer itself.

The sites posted are free but using your own domain name might cost a fee.
Thank you. I wanted to use DuckDNS, but unfortunately they require you to sign in with an account from another service, none of which I have or care to have at this point in time. So I opted for a different provider.
 
Old 02-18-2020, 04:43 PM   #4
resuni
Member
 
Registered: Oct 2009
Location: Colorado, USA
Distribution: I use Arch btw
Posts: 142

Rep: Reputation: 12
I've never used dynamic DNS, but this is certainly possible to do. I wrote a Python script that checks what my IP address is, and compares it to the current A record of my domain name. If it is different, it will update the A record of my domain name via CloudFlare's API. I have this script run on a cron job on a raspberry pi powered by the USB port of my modem, so I have it run periodically as well as every time my modem (and hence the pi) reboots.

This method obviously requires you to be using a DNS provider with an API. The raspberry pi part is optional. In my case, I did it that way because I know my IP address will change if my modem reboots.

I don't know if this is better than using a dynamic DNS provider, but it was easy enough to implement and hasn't failed me yet.
 
1 members found this post helpful.
Old 02-19-2020, 10:56 AM   #5
lqnmp
LQ Newbie
 
Registered: Jan 2020
Location: UK
Distribution: Ubuntu Mate, mainly.
Posts: 3

Rep: Reputation: Disabled
I do this with all my machines. My domain registrar (Mythic Beasts, whom I'd thoroughly recommend) have an API for dynamic DNS changes which saves the hassle of trying to find external IP addresses. I've got raspberry pi-like devices running behind my routers to regularly update the IPv4 address and all my machines will update their IPv6 addresses so I can access any of my machines from anywhere else. Works a treat.

I used to run a cron job but nowadays I use a little snap I hacked together. I just install it on any new device, configure and forget about it.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
DNS - resolv.conf with custom tld (top level domain) domain directive rubanek Linux - Networking 1 06-04-2013 12:11 PM
Using sed regex to remove the top level domain from a fully qualified domain name linux2man Programming 6 12-01-2011 03:38 PM
emacs in run level 3 then switch to X (level 7) then back to level 3 dsoliver Slackware 3 09-01-2006 03:31 AM
Dynamic name resolution for dynamic IP merlin740 Linux - Software 2 10-04-2004 05:56 PM
DNS & Top Level Domain JJX Linux - Networking 2 03-28-2004 07:56 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 12:02 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration