sendmail: using sendmail as submitting MTA

Bernt Hansson bah at bananmonarki.se
Mon Jun 27 13:33:24 UTC 2016


On 2016-06-27 12:03, O. Hartmann wrote:
> We use a monitoring server (icinga2) based on FreeBSD embedded in a closed
> network (no external access) with a M$ mailexchange server.
>
> I try to configure local sendmail in a way so that all email going to the
> localhost are delivered to the local machine itself, but email for an external
> email account is passed to the mail hub server. This mail hub server is
> accessible by any host in the closed network without authentication (this is
> given by a higher instance as a fact I can not change).
>
> I tried to figure out with the recent handbook but the explanation of how to
> configure sendmail is really poor. Since I'm not that familiar with sendmail
> itself anymore, I appreciate some startups here.
>
We have that setup here.

You need to edit hostname.mc and find the line

dnl define(`SMART_HOST', `your.isp.mail.server')

Our's look like this

define(`SMART_HOST', `[10.0.0.1]')

The IP must be like that verbatim.

Then in /etc/mail make all install restart
Just tested on a few machines and they work like you wanted.
Local mail delivered locally and external goes externally.



More information about the freebsd-questions mailing list