On 2023-07-10 at 05:34:44 UTC-0400 (Mon, 10 Jul 2023 10:34:44 +0100)
Ken Gillett via Postfix-users <k...@groups.ukgb.net>
is rumored to have said:

It is many years since I set up postfix on my Mac server and it's use is now purely for local email, i.e. users on home network. However I have some issues with this and could really do with some help.

First of all, changes I have made in main.cf are not being used. AFAICT I am editing the main.cf that is used:-

        ps ax | grep master => master -c /Library/Server/Mail/Config/postfix

So main.cf in that directory is the one being used, but changes to that file are ignored. I'm kinda stuck trying to figure out what appropriate changes to make when I don't know how to actually make any changes to the config being used.

That's apparently an installation done by Apple's "Server" product, which has been abandonware for some years. Changing it through the Server.app administrative tool is one strong possibility for something that will work for you. As for why your changes did not take, I have 2 theories:

1. You didn't restart Postfix after the changes (easiest fix!)

2. When you restarted Postfix, the Apple tools rebuilt main.cf and master.cf from its (hidden in a plist somewhere?) configuration and the *.cf.proto files in that same directory.

I have not touched Server in quite a while, but if I recall correctly, (2) is always going to happen if you use Server (or launchctl) to restart Postfix. The actual .cf files are just for runtime use, not direct editing.

What does 'postconf -d' show?

I know it is supposed to be the 'defaults', but from where is it getting those defaults? Hard coded into the executable?

As I understand it, yes.

If so, how come myhostname, mydomain and mynetworks all contain data specific to my network.

All of those have programmatic defaults, and they are expanded at postconf run time to give operating defaults that are likely to be right for you. You may notice that 'postconf -n' gives different values if you've explicitly set any of those attributes. Reading the comments in main.cf and/or the man pages for postconf(1) and postconf(5) may help clarify.


It is almost as if the configuration being used is an amalgam of main.cf in the above directory and also from /etc/postfix, but I don't believe postfix does that sort of thing.

Correct. It does not. OTOH, the MacOS X Server software that manages Postfix does undocumented things under the hood that thwart direct editing of its runtime config files.

As I said, many years since I last played with postfix and could do with some assistance.

As someone who has run Postfix on MacOS for 17 years, my most vehement advice is to get off the old unpatched Apple-customized and abandoned FOSS components in the old Server package and update to current versions NOT managed by Server. You can build everything on your own and I expect that you can use Homebrew to build them if you prefer, but my personal preference is using the MacPorts versions. Postfix, Dovecot, BIND, and all their dependencies have working ports.

If you were "all in" committed to the Server environment, with its integrated calendar, directory, push notification, and other tools, it is extremely painful to reconstruct that all by yourself with the underlying FOSS tools, but that's the best choice at this point.




--
Bill Cole
b...@scconsult.com or billc...@apache.org
(AKA @grumpybozo and many *@billmail.scconsult.com addresses)
Not Currently Available For Hire
_______________________________________________
Postfix-users mailing list -- postfix-users@postfix.org
To unsubscribe send an email to postfix-users-le...@postfix.org

Reply via email to