How to Install dnsmasq caching DNS server in Ubuntu

As you may have noticed in recent days, my domain registrar (HostFast) suspended cnx-software.com domain for what I believe are dubious reasons, meaning the site was inaccessible to the outside world and myself. I cannot do much about the latter and I’m held hostage to what the domain registrar’s will, but I was able to access my own website with my domain name after installing a DNS server through dnsmasq on my Ubuntu 20.04 laptop.

Edit: most of the steps below are actually not needed in Ubuntu 20.04, since you could just edit /etc/hosts (step 4). I’ll just leave the instructions below in case somebody needs to install dnsmasq.

Here are the steps I followed.

  1. Install dnsmasq
  2. This did not work at first since systemd-resolved is already installed, so I disabled it by following instructions on askubuntu:
  3. I then added name servers to /etc/dnsmasq.conf:
  4. and cnx-software.com IP address to /etc/hosts:
  5. The final step was to restart dnsmasq:

And… magic! I was able to access my own website again through my local DNS server.

cnx-software.com DNS server dnsmasq

With some websites, you could just type of IP address in the web browser, but since CNX Software is relying on WordPress, the domain name lookup needs to work for the website to render properly. At least now, I can write articles (and talk to myself!), which is a massive improvement, as I was not able to access my own website previously.

DNS is a centralized system which means anybody is at the mercy of higher powers, bad actors, and so on. I feel it is not ideal, but there’s no proper alternative to DNS right now, and becoming your own domain registrar is challenging and/or costly…

Share this:

Support CNX Software! Donate via cryptocurrencies or become a Patron on Patreon

ROCK Pi 4C Plus
Subscribe
Notify of
guest
The comment form collects your name, email and content to allow us keep track of the comments placed on the website. Please read and accept our website Terms and Privacy Policy to post a comment.
23 Comments
oldest
newest
Jens Bauer
Jens Bauer
7 months ago

Ehm …
Couldn’t you just have added this line to the /etc/hosts file …
96.126.96.41    www.cnx-software.com
… ?
(that’s what I do)

domih
domih
7 months ago

Yep. Ditto. Thanks to tkaiser for answer on HK forums.

domih
domih
7 months ago

@Jean-Luc
How about transfering your DNS entries from HostFast to GoDaddy?

Jens Bauer
Jens Bauer
7 months ago

It doesn’t look like it’s possible (seems to me like they’ve blocked domain transfers).

domih
domih
7 months ago

Yes, but you should have a gui somewhere to unlock the transfer block. GoDaddy has pages describing the howto for various registrars. I had the issue with register.com in the past, this registrar from hell hid the option deep in their pages…

Rob Logan
7 months ago

are you able to edit your NS record?
 Registry Domain ID: 1585438501_DOMAIN_COM-VRSN
  Registrar URL: http://www.publicdomainregistry.com
  Updated Date: 2022-03-31T08:57:01Z

Jens Bauer
Jens Bauer
7 months ago

Note: I’m using OpenDNS and the propagation took a while before the domain was pointed to the ‘suspended server’. This is why I could write a comment early on and also grab the IP-address and place in my own hosts file (until the domain is no longer suspended). I’ve attempted to set up cnx-software.multitrading.dk -This will likely not work for several reasons: 1: The server is probably name-based, so nginx wouldn’t recognize the domain. 2: The certificate will not be valid (Jean Luc can use a self-signed certificate, though). Jean Luc can of course modify the server to accept the… Read more »

Jens Bauer
Jens Bauer
7 months ago

Actually cnx-software.multitrading.dk seem to work; though the content seem a little different (I don’t see this dnsmasq page).
-So you should be able to go to the above mentioned subdomain+domain until the original domain is available again. =)

sander
sander
7 months ago

and no comments.

Jens Bauer
Jens Bauer
7 months ago

and no comments.

… Which means it’s much better to use cnx-maker.net =)

(Though my quick solution isn’t necessary any longer, I don’t see any reason to take it down until the original domain is up again).

Theguyuk
Theguyuk
7 months ago

I just read it via bestline vpn

Willy
7 months ago

Jean-Luc, I’d like to contact you offline but I can’t since your mail address is on your domain. I’m seeing simple solutions on how to help you but discussing them publicly would defeat them, so please contact me privately then you can delete my message 🙂

maurer
maurer
7 months ago

it seems it works now – is it solved ?
anyway I recommend transferring your domain to njal.la – it was created by one of the tpb founders to resist censorship and abuse – the things you were subjected to for the past week

tkaiser
tkaiser
7 months ago

Check the FAQ for what they do with domains: https://njal.la/faq/

maurer
maurer
7 months ago

they wanted to become a registrar but got denied because of political/activism history. anyway as I’ve read below it wasn’t really a censorship issue so njal.la is not necessarily the silver bullet for your kind of issue.
Anyway I’m very glad it’s solved – you’re my main technology blog !

S K
S K
7 months ago

Can you share a bit about what those dubious reasons were? Might be useful for others out there experiencing the same in the future.

Anonymous
Anonymous
7 months ago

How much business (or traffic) has been lost because of this dust-up?

Weller PCB manufacturer