Website doesn't load on Virtualmin

SYSTEM INFORMATION
OS type and version: Ubuntu Server 20.04
Webmin version: 1.981
Virtualmin version: 6.16
Related products version: N/A

Hello, I am currently trying to set up a website hosted by myself on Virtualmin. I have nameservers registered on Namecheap pointing to my server. My server hostname is uk1.everycloudhost.com. The subdomain on Ionos, uk1.everycloudhost.com has its nameservers set to mine: ns1.everycloudhost.com & ns2.everycloudhost.com both pointing to the server ip. I have tried to fix this by adding 127.0.0.1 to the /etc/resolv.conf but it gets overwriten on reboot. After this, I installed resolvconf and followed a guide editing a separate file that had a symlink that added 127.0.0.1 to /etc/resolve.conf. /etc/resolv.conf also has the line nameserver 127.0.0.53 which seemed strange to me. The uk1.everycloudhost.com subdomain does not resolve publicly and only locally on the server. Are there any ideas of what could be going on? Many Thanks.

Sounds like you haven’t delegated DNS to the Virtualmin server.

If you are managing DNS outside of the Virtualmin system, you’ll need to add an A record for the subdomain wherever you are managing the DNS.

The virtualmin server is the DNS, I have created the default virtual server as prompted after the install wizard on Virtualmin. How can I delegate DNS?

That depends on your DNS registrar. You need glue records pointing to your Virtualmin server (and you’ll need two IPs on it, or a second server that is a DNS secondary). How you configure those glue records is entirely up to your registrar and nothing something we have any control over. Probably called just “Name Servers” or similar.

I have two nameservers that can be resolved publicly: ns1.everycloudhost-dns.co.uk and ns2.everycloudhost-dns.co.uk. They are both registered with namecheap like on the documentation here: DNS Frequently Asked Questions | Virtualmin

Both nameservers are pointed to my server ip.

By “hosting yourself” do you mean you installed Virtualmin on your own computer at your house and you’re hosting it via your home internet connection?

Yes, I have a dedicated PC running Ubuntu Server as mentioned. Public IP and port forwarding all fine.

If you go to your virtual server and preview the site, do you get the site preview? Does that work OK?

Well I can see on my Virtualmin page the Virtual Server Summary page, this is a remote server and not at my house, while it is still technically a ‘home server’ it’s being hosted at a spare space in my friends apartment. I use ssh for this and if you’re talking about previewing the site locally its not very possible. I have actually managed to get this to work before in the past but that was a while ago and my memory has gone as well as the data as it was wiped after a RAID error. I know asking this seems quite unprofessional but by any chance do you have some place I can chat to you on to message quickly. If you have Discord my username is: vapouryh#4448.

I gave up on Discord when they asked for my cell phone number.

Log on to Virtualmin, go to the virtual server, look down below the virtual server summary and about 10 or 11 items down you should see SERVICES. Click that and it will open up some more options and in there you will see PREVIEW WEBSITE.

Click that and see if it works. If it does, then you’re site and server setup are OK and it’s going to be a DNS issue more than likely. If it doesn’t work, then you have issues with the configuration from the outset.

Yep, that works fine. It has to be a DNS issue then. I don’t particularly know where the fault is. I do have an outstanding balance on my IONOS account, this is the one the domain everycloudhost.com as well as the subdomain uk1.everycloudhost.com are registered. I have an outstanding balance on a different service on that account know, but I doubt it’s related to my issues. Do you have any recommendations or steps to take?

You have no SSL working. I’m wondering if that could be part of your issue. Even your Virtualmin login at port 10000 is unsecured.

I’m not sure its possible to get SSL for an ip address. I can’t login from the website but it’s self-signed i’m pretty sure.

Virtualmin / Server Configuration / SSL Certificate

See what it says under current certificate.

Yes, it’s self signed. I can’t use let’s encrypt due to the subdomain not being able to be resolved. The nameservers for the subdomain are set so I don’t see the problem.

What you do is get a lets encrypt for the default server. Then you copy that to everything else. That should be in place before you even create the subdomain.

The server i’m hosting off is the subdomain. The domain: everycloudhost.com is still under IONOS management.

SSL is irrelevant to this problem.

Are these your name servers?

$ whois everycloudhost.com|grep Nameserver
Nameserver: ns1041.ui-dns.de
Nameserver: ns1023.ui-dns.biz
Nameserver: ns1023.ui-dns.org
Nameserver: ns1120.ui-dns.com

If not, you have not delegated authority for your domain to your server. DNS records configured in Virtualmin are meaningless to the world as long as your Virtualmin server is not the authoritative DNS server for the zone.

Now I’m confused.

When I go to everycloudhost.com I see a Virtualmin domain.

I’m about to have to go to cook dinner, but if you’re using IONOS for that domains DNS and you’re hoping to magically use Virtualmin for the rest of the DNS that isn’t going to work out well for you unless you REALLY know what you’re doing.

You’d be better served to create a free Cloudflare account, follow the directions for it to point the nameservers of your main domain to it. Then you can create the A record for the subdomain and point it to your IP and it’ll work like a charm.