1 (edited by thelocalhost 2018-08-30 17:36:29)

Topic: Proper configuration of DNS for another e-mail domain.

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 0.9.8
- Linux/BSD distribution name and version: CentOS 7
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Web server (Apache or Nginx): Ngnix
- Manage mail accounts with iRedAdmin-Pro? Yes
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

The idea is simple: I would like to have a single mail server, where I could manage e-mails for multiple domains.
The catch is that, that this mail server should be mail server only.

Example:

Servers:
100.0.0.1: Mail server
200.0.0.1: Web server

Domains:
my-mail-server.com
foobar.com

I've configured DNS of my-mail-server.com to point entirely to 100.0.0.1.
Also I've added SSL cert from certbot :)

Questions that I have:
1) How to configure DNS entries for foobar.com domain, so that iRedMail would do it's magic of managing multiple domains? And, of course that I would receive e-mails on my mailbox from outside the world ;)
2) Is it something else required besides adding domain & user in iRedMail admin panel?
3) Should I also re-create SSL cert that is used on my-mail-server.com, so that it would contain cert for foobar.com also?

I hope that someone have done such a config and could help me with mine :)
Thanks in advance!

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2 (edited by swejun 2018-08-30 22:27:36)

Re: Proper configuration of DNS for another e-mail domain.

Hello localhost.
DNS First:
In order for allow incomming e-mail  to your domains, the domain should have the MX record set .The MX record tells which host is responsible for incomming email. In Your case, the MX record for my-mail-server.com and foobar.com should both point to an DNS server name, which points to the IP address 100.0.0.1 via an "A" record.

Note, the name+domain of the Mail server, does not need to mach the domain where the MX sits
Example:
DNS Domain= mydomain.com
  MX  10  mailserver.mydomain.com 
  A    mailserver.mydomain.com 100.0.0.1

DNS Domain= foobar.com
  MX  10  mailserver.mydomain.com

When an external mailserver tries to send mail to user@foobar.com, it will look for the MX record in the foobar.com domain,
and find out that the receiving host is mailserver.mydomain.com, then check for an A record of this hostname, and delivers to 100.0.0.1

For a user@mydomain.com, it will finf the MX and A record from the DNS server for mydomain.com and deliver to the IP adress as above.

The second issue is that you want to run the Web GUI for tha mail server in another box called webserver. I assume that
it is sitting in the same domain "mydomain.com", so you would need a DNS entry for an A record
A    webserver.mydomain.com 200.0.0.1

Thirdly, you would need to figure out how to split the web server part and the mail server part, but that's another story ;-)

thelocalhost wrote:

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 0.9.8
- Linux/BSD distribution name and version: CentOS 7
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Web server (Apache or Nginx): Ngnix
- Manage mail accounts with iRedAdmin-Pro? Yes
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

The idea is simple: I would like to have a single mail server, where I could manage e-mails for multiple domains.
The catch is that, that this mail server should be mail server only.

Example:

Servers:
100.0.0.1: Mail server
200.0.0.1: Web server

Domains:
my-mail-server.com
foobar.com

I've configured DNS of my-mail-server.com to point entirely to 100.0.0.1.
Also I've added SSL cert from certbot smile

Questions that I have:
1) How to configure DNS entries for foobar.com domain, so that iRedMail would do it's magic of managing multiple domains? And, of course that I would receive e-mails on my mailbox from outside the world wink
2) Is it something else required besides adding domain & user in iRedMail admin panel?
3) Should I also re-create SSL cert that is used on my-mail-server.com, so that it would contain cert for foobar.com also?

I hope that someone have done such a config and could help me with mine smile
Thanks in advance!