Diese Seite in Deutsch.
Since Mac OS X 10.3 sendmail has been replaced by Postfix. This means this page is obsolete.
At the time writing this I stopped using sendmail on Mac OS X - I switched to Postfix. But I have a good hint:
As usual with system daemons on it isn't sufficient to change the corresponding value in /etc/hostconfig to
MAILSERVER=-YES-
and to run the startup-script - it will fail! This is the error message you will get:
root@lampe:~$ /System/Library/StartupItems/Sendmail/Sendmail start
Starting mail services
451 4.0.0 /etc/mail/sendmail.cf: line 94: fileclass: cannot open '/etc/mail/local-host-names': Group writable directory
I is well known that sendmail is very picky about
writing permissions of directories. But it takes some
time to find out it is actually / having the wrong
permissions.
To solve this problem finally, even after system upgrades
which reset the permissions to the wrong values, I added
two lines to /System/Library/StartupItems/Sendmail/Sendmail:
/bin/chmod go-w / /etc /etc/mail /usr /var /var/spool /var/spool/mqueue
/usr/sbin/chown root / /etc /etc/mail /usr /var /var/spool /var/spool/mqueue
This corrects the directory permissions whenever you start sendmail. I've found these commands at kung-foo.tv.
No your system is able to receive mail, but it still isn't configured properly. Apples defaults it is shipping sendmail with don't necessarily have to be right for everybody.
I tend to make manual changes in /etc/mail/sendmail.cf as long as it is about options. But changing rulesets is far too complicated! So we need a new sendmail.cf - and this is being done using m4-macros.
Letting m4 generate a sendmail.cf from a sendmail.mc isn't very difficult. Apple has placed a very helpful and easy to understand /etc/mail/README which explains what to do, and even more. It helped me succeed right away so I guess I don't have to go into details here.