Can’t access the server via hostname

In that case it would look as if you haven't setup your hostname on directadmin itself correctly. However, the hostnamectl is giving the correct output, so that is odd.

The server-172-102-243-9.da.direct is something DA started with a few years ago (I'm not happy with it either) while before they just used the hostname if available. And to make things start working for users who don't now how to setup a hostname correctly or want to do that later on.
This is done by DA to be sure users can access the DA panel via https after they installed Directadmin.
So this is also the reason this is autodetected and pointed out as to visit to be able to enter Directadmin.

Also, this is my hostname info, which was set prior to running the setup script.
That part is indeed odd. Check with both the commands hostname and hostname -f if both are giving the correct hostname. I've installed a server 2 weeks ago where these commands gave the correct hostname output. And DA was setup with the correct hostname.
If these command now give out the correct hostname, but DA was still installed with the ipxadres-da.direct hostname, then something might have gone wrong in the latest DA version build.

Doublecheck that both /etc/hostname and /etc/hosts have the correct chevell.prima42.net hostname present in there.
Also login to DA and change your hostname in there if that is still pointing to the da.direct hostname.

After that, add your hostname record. Since you use external mail and DNS anyway, easiest way is to add the A record for the hostname in your domain DNS on DA and on your domain DNS external.
Then it should in fact be working.

However I wonder if you have waited long enough after installation, because based on nslookups, all is pointing out correctly.

I will explain.
When doing a DA setup, then Directadmin itself is installed quite quickly nowadays. But that is only the panel so you can have a look around.
However, everything else (apache, exim, mariadb etc.) is installed in the background. You will get a notification in the message system of DA if all that is done and ready.
To my experience it is best to not start changing things in the DA setup, until you have got that message that everything is ready.

Because even if you domain is not setup correctly, when using http:/172.102.243.9:2222 DA should work anyway.
And in your case that is not happening. So it seems Directadmin is either not running at the moment, or something went totally wrong during installation, maybe because you acted too soon or something else went off.

Could it be you started to soon working in the DA gui?
 
In that case it would look as if you haven't setup your hostname on directadmin itself correctly. However, the hostnamectl is giving the correct output, so that is odd.

The server-172-102-243-9.da.direct is something DA started with a few years ago (I'm not happy with it either) while before they just used the hostname if available. And to make things start working for users who don't now how to setup a hostname correctly or want to do that later on.
This is done by DA to be sure users can access the DA panel via https after they installed Directadmin.
So this is also the reason this is autodetected and pointed out as to visit to be able to enter Directadmin.


That part is indeed odd. Check with both the commands hostname and hostname -f if both are giving the correct hostname. I've installed a server 2 weeks ago where these commands gave the correct hostname output. And DA was setup with the correct hostname.
If these command now give out the correct hostname, but DA was still installed with the ipxadres-da.direct hostname, then something might have gone wrong in the latest DA version build.

I can see the logic in that I guess. I mean, it appears that it may have actually worked in my favor here to give me access to the admin. Here is the output of both variants of the hostname command:

Code:
╭╴ HOST: chevelle | USER: root | PATH: /var/named
╰──╢ ? 10:08 AM ║ #» hostname
chevelle.prime42.net

╭╴ HOST: chevelle | USER: root | PATH: /var/named
╰──╢ ? 10:45 AM ║ #» hostname -f
chevelle.prime42.net


Doublecheck that both /etc/hostname and /etc/hosts have the correct chevell.prima42.net hostname present in there.
Also login to DA and change your hostname in there if that is still pointing to the da.direct hostname.

Here are the contents of said files:

Code:
╭╴ HOST: chevelle | USER: root | PATH: /var/named
╰──╢ ? 10:45 AM ║ #» cat /etc/hostname
chevelle.prime42.net

╭╴ HOST: chevelle | USER: root | PATH: /var/named
╰──╢ ? 10:47 AM ║ #» cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
172.27.27.209        chevelle.prime42.net chevelle

It should be noted that IP is the correct LAN IP the interface is bound to. Incoming traffic goes through a hardware firewall and there are firewall rules and port forwarding coming in, and outbound NAT so traffic always routes out on the correct WAN IP.

After that, add your hostname record. Since you use external mail and DNS anyway, easiest way is to add the A record for the hostname in your domain DNS on DA and on your domain DNS external.
Then it should in fact be working.

However I wonder if you have waited long enough after installation, because based on nslookups, all is pointing out correctly.

It has been a full day, and all my TTL with a few rare exceptions are set to 300.

I just navigated to Dashboard / DNS Administration / DNS Administration clicked + Add DNS Zone, and created an entry for chevelle.prime42.net with the IP address and my Name Servers (I actually have 4 rather than 2, but that should not matter, right?)

With this edition I am now able to get to the login form. It is not accepting my password, but that is a completely different issue. So I guess now I have a lot of documentation to read.

I will explain.
When doing a DA setup, then Directadmin itself is installed quite quickly nowadays. But that is only the panel so you can have a look around.
However, everything else (apache, exim, mariadb etc.) is installed in the background. You will get a notification in the message system of DA if all that is done and ready.
To my experience it is best to not start changing things in the DA setup, until you have got that message that everything is ready.

Because even if you domain is not setup correctly, when using http:/172.102.243.9:2222 DA should work anyway.
And in your case that is not happening. So it seems Directadmin is either not running at the moment, or something went totally wrong during installation, maybe because you acted too soon or something else went off.

Could it be you started to soon working in the DA gui?

No, a couple hours went by before I first logged in to DA, and when I did the message was already there.

I see that chevelle.prime42.net.db now exists in /var/named and it is populated as I would guess. So am I to assume those need to exist but once everything in DA is configured they will basically be ignored as to the contents of them? Right now with cPanel that appears to be the case. I only need to worry that Route 53 is correct.
 
Here are the contents of said files:
I don't need content, you're managing multiple servers so if you say it's present in the correct way then I believe you. ;)

I just navigated to Dashboard / DNS Administration / DNS Administration clicked + Add DNS Zone, and created an entry for chevelle.prime42.net with the IP address and my Name Servers (I actually have 4 rather than 2, but that should not matter, right?)
No, that doesn't really matter. If you just enter ns1 and ns2 that would be sufficient, it's just that DA has something to use.
Good to hear you can visit it now, probably you have protected or limited your ip as I still can not view the login page. But that doesn't matter, if you can visit it now then it's fine.

No, a couple hours went by before I first logged in to DA, and when I did the message was already there.
Ah oke, I just asked to be sure because there are a lot of first times on DA who don't know and start doing all kind of stuff.
Depending on resources and cpu speed etc. a full installation would take something between 25 minutes and 1 hour.
On an i7-7700 with 64 GB RAM and 2 sata SSD's in raid 1 it takes 24-25 minuts, so that gives some indication.

You might want to check if a chevelle.prime42.net directory exists in /etc/virtual at least if system messages are send via the hostname.

Yes they need to exist locally since DA needs them to work internally. So if you point in your route 53 an A record to a domain, then DA knows where to look locally. So it's not fully 100% ignored, but it's not used as authoritative, only internal purposes. That part works the same as with cPanel does.

The route 53 requires to be correct indeed, because you set that as the NS with the registrar, so that is where all systems will be looking at. No difference in that either.

Still... maybe you can configure LEGO in DNS, then if you change some domain record (or ad a subdomain) in DA, the according DNS records are updated via Lego in Route 53 automatically, no manually action required anymore.
Provided Route 53 can be configured in Lego.
 
I have the external DNS configured correctly. It was configured prior to running the setup script, with the exception of the PTR record for the IP it is hosted on. I have done nothing with internal, as I can't find any domains or zones anywhere.

I am going to give some specifics to make it more clear.

The admin loads fine from http://server-172-102-243-9.da.direct:2222/ (I think it got that domain from the reverse DNS on the IP) but will not load at all from https://chevelle.prime42.net:2222/. If you query both server-172-102-243-9.da.direct and chevelle.prime42.net you get the same IP address:

Neither one work for me.
 
Neither one work for me.
That would be because I don't allow the open internet access to administrative interfaces. You shouldn't either.

As I stated before, this server is for internal things only, no clients on it. So in this case there is zero reason to allow access to DirectAdmin to anything other than pre-approved administrative IPs.
 
That would be because I don't allow the open internet access to administrative interfaces. You shouldn't either.

Well I have customers that need it. If I don't have customers then I don't need DirectAdmin at all and neither do you. I am sorry, did I presume to know your circumstances?
 
My circumstances are described in the above posts. Perhaps you just missed them. I was fairly clear though.

Also, the issue is no longer an issue. So I am no longer in need of assistance.
 
My circumstances are described in the above posts. Perhaps you just missed them. I was fairly clear though.

Also, the issue is no longer an issue. So I am no longer in need of assistance.

I was offended when you told me what I should do when you know the vast majority of us use DA for webhosting in which clients need to access DA. We cannot just firewall it and you know that. I was trying to help. You can see that I am one of the more experienced ones here. Not wise to take a shot at ones who are in a position to help you.
 
Back
Top