2

I have enabled email notifications in Server.app (2.2.4) on Mac OS X server (10.8.5)

If port 25 is not being blocked at the local firewall or the ISP, this generally works ok.

I've found that if it is being blocked by the ISP, you can go the mail settings within server.app, and set mail to route all mail traffic through ISP and specify your ISP's SMTP gateway, even if you don't actually have the mail server enabled and/or use the mail server.

The problem that I've run into is that I have a client who uses an email hosting provider that requires a valid MX record for the domain that an email is coming from.

Their [email protected] where they want to receive their Mac OS X server alerts cannot receive the alerts because the messages are seen as coming from an invalid domain with no MX record.

The Mac OS X server is called macminiserver01.local or macminiserver01.private and when the email alerts are sent out from server.app, the from address becomes [email protected] or [email protected].

Is there a way to manually change the from address so that it is valid?

2
  • What version of Server.app is running and what OS X runs that app?
    – bmike
    Oct 21, 2014 at 12:25
  • This particular issue is Mac OS X 10.8.5 with server.app 2.2.4. However, I support many customers in a similar configuration. Some of them are 10.7.x Mac OS X with similar version of server.app and some of them are 10.8.x Mac OS X with similar version of server.app. As far as I can tell, there is not any difference between the configuration of the alerts for the various setups that I maintain. Oct 22, 2014 at 5:00

1 Answer 1

2

I know this question is a few years old, but I had the same issue some up today. I resolved it with help from this post:

https://www.cyberciti.biz/tips/howto-postfix-masquerade-change-email-mail-address.html

This was on a Mac server that did not have mail enabled. Apparently even with postfix disabled, the alerts function fires it up just long enough to send the alert email and then closes it again. Running nettop while sending the test alert email lets you see sendmail kick off, followed by postdrop, master, pickup and qmgr.

I found five different locations for the main.cf file file, but the one that seemed to be active was located in:

/Library/Server/Mail/Config/postfix

Edit that file to append this line:

smtp_generic_maps = hash:/Library/Server/Mail/Config/postfix/generic

Then edit generic by appending the mapping you want:

[email protected] [email protected] Then run:

postmap /Library/Server/Mail/Config/postfix/generic

2
  • Thanks. This totally solved a years long outstanding issue I had with a particular client. One thing to note is that the last command should be "sudo postmap /Library/Server/Mail/Config/postfix/generic" Apr 26, 2017 at 2:52
  • Works. And don't forget to reload postfix. :)
    – StevieD
    Sep 7, 2021 at 20:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .