NethServer and Exchange

Hi All,

I’m new to Nethserver coming from another distro. I have searched but I couldn’t find an exact howto…Maybe I had a man look…
In brief, I have this scenario for incoming/outgoing email:

BigBadWorld > Router > Linux > Exchange server

Email comes to the linux box, gets filtered and scanned for viruses and then forwarded onto the exchange server.

On the way out, exchange uses the Linux box as a SmartHost through a linux user and password,
and the process is reversed.

How do I forward email from Nethserver to exchange (I have the email modules installed on NethServer, and do I still use a linux user and password to send email from the exchange box?

Thank you in advance…

BM

NethServer Version: your_version Latest
Module: your_module

@bm777

Hi

And welcome to the NethServer community!

It can be even simpler…

For Outgoing:
You can set the smarthost to allow the trusted IPs of your LAN to send Mail without authentification…
I’d still suggest using a Linux User (eg: smtpuser) for your smarthost…

For Incoming:
You can forward all mail for a certain, defined domainname to another server.
You also have the option to forward mail “per user”.

My 2 cents
Andy

2 Likes

HI Andy and thanks for your kind and prompt reply…I’d keep things easy and forward the entire mail to exchange, but when I go and do that, the option is greyed out…
I hope I’m under the correct option…
Applications > Email > Domains > Edit and “relay to another server”
Option greyed out…

First create a new domain…

Hi there and thanks for the reply…OK…So I will have to place the NethServer onto his own domain and then forward to the existing exchange domain…
Right…So I take there is no way to rename the domain/hostname without re-installing…
Sorry about all the questions…Once I have got this right I will make a how to for anyone in this predicament…

Hi

You CAN change the domainname / IP of your NethServer if you haven’t installed an account provider yet.
If you remobve the account provider, you can change the domainname / ip, and then re-add the account provider…

My 2 cents
Andy

1 Like

:+1: Thanks…Sorry for being a pain…

1 Like

Hi

No probs!
I’m here to help!

:slight_smile:

Thanks guys…It is really appreciated…Will let you know tomorrow as I’m installing in client network…

2 Likes

Hi Andy…
Say the domain is company.com
The new nethserver name is neth1.company.com setup after install.
When I go to create “company.com” domain in the email section, I can type in domain.com and forward to ip address say 192.168.1.7 or mail.company.com, but when I click on save, nothing happens and the form stays there…
Thanks

Hi

You can delete the default domain, as shown here. Then create a new domain as required…
This is domains in the e-mail “app”.

Hope this helps…

:slight_smile:

My 2 cents
Andy

Hi Andy,
I think the issue is that the nethserver is on the same domain company.com, it won’t let me create the company.com domain and forward email to the specified exchange server.

I can create the company.com but it does not allow me to relay to another server…
If I create company.com and then go back and try to click on the relay radio button, the option is greyed out…
Thanks

Hi

Create a “fantasy” domain like mailrelay.domain.tld for the NethServer.
The fqdn would be nethserver.mailrelay.domain.tld
Then the original domain is free and untainted…

My 2 cents
Andy

Hey Andy, OK that works. However, just worried that when email arrives or gets sent via nethserver it will get rejected because of a dummy domain?

Good point, for outgoing, however:

There IS a howto on this forum how to set the smtp helo on Postfix… (NethServer uses Postfix).
This so other mailservers see the name as valid from the outside - whatever it may be…
Usually mail.domain.tld…

Here:

:slight_smile:

Not sure why I received this email from you… The how to you mention is exactly my message in the forum explaining how I did it.

???

Anyway, have a good day :slight_smile:
J.

Unfortunately it does not work here.
I have one NS system A in a VPS with a fixed ip address installed and another NS B sits in the home network. A shall work as mailscanner: all mails shall be checked by A and then forwarded to B. In fact the mails are rejected: recipient unknown.
I have even connected B with the LDAP server in A. So B knows all users and mailboxes in A, but still the mails are not relayed.
Who can help here?

So alpha.yourdomain.org should be the one the VPS, and should handle the email messages for yourdomain.org, and be considered the mail exchanger and written in your DNS server.
And beta.yourdomain.org should receive messages after the mailwashing.

How alpha.yourdomain.org is supposed to deliver messages to beta.yourdomain.org?

By configuring domain in NS A as all mails to be delivered to B.
I used Xeams before and that was never a problem. But after three months I got hustle with the letsencrypt certificate.

This is how alpha.yourdomain.org can receive all the messages for the domain. But how is supposed to deliver messages to beta.yourdomain.org?

Also: which of the two servers is the one written into MX record? alpha.yourdomain.org as I supposed or the other one?