NS8 & hostname again

Hi all,

I installed a new Debian-12.1 minimum, aupdate etc…

In /etc/hostname, I put the recommanded: ns8.debian.toto-dev.org.

For the host, the content of /etc/hosts was:
127.0.0.1 ns8.debian.toto-dev.org ns8

I Installed NS8-B2.

In some places I saw: ns8.debian,toto-dev.org,debain.toto-dev.org which I corrected to ns8.debian.toto-dev.org.

I installed MAIL and Rouncube.
For MAIL it displays: ns8.debian.toto-dev.org // I changed for my DNS record: mail.debian.toto-dev.org

Roundcube is not accessible even after a reboot…

QUESTIONS:

Now, what should be the content of /etc/hostname ?
What should be the FQDN for the mail DNS record ?

Michel-André

P.S.
No user had an email address after installation of MAIL & Roundcube.

Hi Michel,

I think you are in a wrong track!

There have been a lot of discussions around the hostname. For this reason we decided for Beta 2 to implement hostname setup in the initial cluster-admin configuration.

Where can you find this “recommendation”? I think it no longer applies for Beta 2. Use the UI initial cluster-admin procedure.

The contents of that file must not be changed manually. After completing the cluster-admin procedure you’d expect hostname with no domain suffix. So in your case expect ns8.

This is not wrong, but the expected /etc/hosts record (as documented in the hostname man page and configured by the cluster-admin procedure) is

127.0.1.1 ns8.debian.toto-dev.org ns8    

In any case a similar record is important for the system to find its FQDN. For a quick sanity check, the output of this command must be the expected host FQDN:

hostname -f

The Mail server host name parameter is fully described in the manual, Mail server — NS8 documentation. If you have any doubt feel free to ask.

So, is reinstalling an option? I suggest to reinstall and complete the installation procedure from the cluster-admin UI as described in Installation — NS8 documentation.

The documentation is a work in progress. We strive to keep it up to date with new features and enhancements. Please read it carefully because some things has changed since Beta 1. If something is not clear, feel free to ask.

Hi @davidep

From a reply by Giacomo
What is the hostname format? - #4 by giacomo.

Michel-André

Hi @davidep

You are right.

man hosts

EXAMPLES
       # The following lines are desirable for IPv4 capable hosts
       127.0.0.1       localhost

       # 127.0.1.1 is often used for the FQDN of the machine
       127.0.1.1       thishost.example.org   thishost    <<<=================
       192.168.1.10    foo.example.org        foo
       192.168.1.13    bar.example.org        bar
       146.82.138.7    master.debian.org      master
       209.237.226.90  www.opensource.org

My /etc/hosts

root@ns8:~# cat /etc/hosts
127.0.0.1       localhost
# commented by set-fqdn #127.0.1.1      ns8.debian.toto-dev.org   ns8   <<<=====

# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
127.0.0.1 cluster-leader
10.5.4.1 cluster-localnode
127.0.1.1 ns8.debian.toto-dev.org ns8   <<<=============================
root@ns8:~#

When I entered the FQDN in the UI, it changed my entry in /etc/hosts to the right one.

I will restart brand new.

Michel-André

1 Like

Thank you for pointing it out. I replied also to that thread. Now I hope we did the right choice and we will never need to change it again :smile:

With NS7 we followed the basic distro guidelines. With NS8 we decided to follow common conventions, after checking they suit EL distros too!