Mail-in-a-Box hostname

Hello,
I’m planning to deploy Mail-in-a-Box in a VPS (hosted by Netcup).
As part of the preparation steps I have created some DNS records:

  • A-record: box.mydomain.example [VPS public IP]
  • A-record: ns1.box.mydomain.example [VPS public IP]
  • A-record: ns2.box.mydomain.example [VPS public IP]
  • CNAME: mail.mydomain.example box.mydomain.example
  • CNAME: webmail.mydomain.example box.mydomain.example

However I’m struggling with the server setup.

In Mail-in-a-Box Setup Guide I find this instruction:
For your Mail-in-a-Box, we recommend naming your box box + . + your domain name.

Josh’s Mail-in-a-Box is named box.occams.info. This is its hostname.

Your Mail-in-a-Box may handle the email for multiple domain names, but the box has a single name.

Your box’s name CANNOT be a domain name that you intend to serve a website on from another web hosting service. We strongly suggest using a subdomain like box, as in the example above, so that you are able to use the main domain name for a website hosted from another web hosting service if you choose.

Applying this to my enviroment would mean to set hostname = box.mydomain.example.
I would run command hostnamectl hostname box.mydomain.example.
However in my understanding this is long host name (FQDN), and typically I would set hostname running this command hostnamectl hostname box w/o domain.

Could you please clarify?

THX

I think you don’t need to prepare that many steps before installing Mail in a Box. The box will handle dns, so you don’t need to add those dns records you’re mentioning. Only glue records to the nameservers need to be added, but those are not A records.
The hostname will also be set by the MiaB installation. So you don’t need to do that yourself. It is indeed set to box.example.domain
My advice is to follow the setup guide you found and simply try it out. If it fails, or you want to do something differently, just reset your vps and try again. Most vps providers provide tools to do that easily. Some also provide snapshot functionality. If yours has that you can make a snapshot before installing MiaB. Then if you don’t like your choices you can simply roll back to the snapshot.

Thanks for sharing this information.

I’m struggling with glue records, though.
My understanding was to create A-records ns1.box.domain.example.
In case this is wrong, how can I setup glue records with Netcup?

So the glue records need to be set at your domain registrar. But the process is different for each one. If you can mention the registrar, perhaps someone here can help you if you can’t figure it out. (if you also use netcup as the domain registrar, some info can be found here, it mentions glue records specifically)

Hi, as per the install instructions, for a standard install (definitely the way to start) the only glue records you need are A records (set at your domain registrar) for ns1… and ns2… Everything else is handled by the default MIAB setup :slight_smile:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.