local sendmail server not working in mac os x 10.5.6

i am running os x 10.5.6 on a fairly new imac and also on a fairly new macbook. i am using my local apache server and a mysql database. ever since the last os x download my local mail server hasn't worked on either computer. the sendmail app still appears in /usr/sbin and my php.ini file still contains sendmail_path = /usr/sbin. but the php mail() function no longer works. the same php code runs fine on the web host server that i subscribe to. anyone else encountered this? thanks.

imac, Mac OS X (10.5.6)

Posted on Feb 27, 2009 2:15 PM

Reply
12 replies

Feb 27, 2009 2:39 PM in response to phasorman

First, the obvious - have you started the mail server on the machine (your post doesn't say so).

Second, what do the logs have to say about it (/var/log/mail.log for one).

That might give some hint as to the reason why. Since you don't state whether you're sending mail to local addresses (e.g. within your domain) or remote ones, or what the failure state is (if any), it's impossible to tell from your post, but the above should help.

Feb 27, 2009 4:04 PM in response to Camelot

thanks Camelot

i've been asking this question in different forums for quite a while and yours is the first answer.

unlike the local mysql server, i have never had to start the local sendmail server. it was always running. all i had to do was configure the sendmail path in the php.ini file. here is what the logs used to say when i sent a simple mail message using the php mail() function when everything was working:

Jan 15 11:13:17 ted-clarkes-imac postfix/master[2933]: daemon started -- version 2.4.3, configuration /etc/postfix
Jan 15 11:13:17 ted-clarkes-imac postfix/pickup[2934]: A7A7613F54E: uid=70 from=<_www>
Jan 15 11:13:17 ted-clarkes-imac postfix/cleanup[2936]: A7A7613F54E: message-id=<20090115181317.A7A7613F54E@ted-clarkes-imac.local>
Jan 15 11:13:17 ted-clarkes-imac postfix/qmgr[2935]: A7A7613F54E: from=<_www@ted-clarkes-imac.local>, size=503, nrcpt=1 (queue active)
Jan 15 11:13:52 ted-clarkes-imac postfix/smtp[2938]: A7A7613F54E: to=<clarkee@telus.net>, relay=mx.svc.telus.net[204.209.205.52]:25, delay=35, delays=0.03/0/33/2, dsn=2.0.0, status=sent (250 Ok: queued as AE302737340541BF)
Jan 15 11:13:52 ted-clarkes-imac postfix/qmgr[2935]: A7A7613F54E: removed
Jan 15 11:14:17 ted-clarkes-imac postfix/master[2933]: master exit time has arrived


but here is what they say now when i run exactly the same script:

Feb 16 10:00:28 ted-clarkes-imac postfix/master[279]: daemon started -- version 2.4.3, configuration /etc/postfix
Feb 16 10:01:28 ted-clarkes-imac postfix/master[279]: master exit time has arrived

i sent the mail message to a remote domain. i don't know how to determine the failure state. i don't get an error message from php.

what say Camelot?

Mar 5, 2009 3:34 AM in response to phasorman

Sorry missed that. Was a bit confusing. Let's concentrate on what does not work and forget the past. 😉

First, please check if the logging level for SMTP is set to "Information". If it isn't, set it. If it is, change it to a different level, save and change it back "Information".

Try to send and see if there is any log info. If there isn't check the apache log for clues.

Mar 5, 2009 3:42 PM in response to pterobyte

hello again pterobyte. i see nothing in the apache logs concerning the mail server at the times i sent the mail. i looked but could not find out how to change the logging level. i'm fairly new to unix.

i know for sure that after the os x upgrade my mail message was no longer received by the recipient. do you have a mac and does your local mail server work using 10.5.6? do you use the php mail() function? do you know if it possible to report a problem to apple? i have tried their support but no luck.

i appreciate the time you have spent on this. thanks a lot.

Mar 6, 2009 3:56 AM in response to phasorman

i see nothing in the apache logs concerning the mail server at the times i sent the mail

Do you actually see your PHP app sending?

i looked but could not find out how to change the logging level.

Server Admin -> Mail -> Settings -> Logging.

do you have a mac and does your local mail server work using 10.5.6?

I manage dozens of OS X Servers. No problems whatsoever.

do you use the php mail() function?

yes, among others

do you know if it possible to report a problem to apple?

Have you tried looking for it? 😉
http://www.apple.com/feedback/
http://developer.apple.com/BugReporter/

However, there is no bug. It must be your setup.

Mar 6, 2009 8:34 AM in response to pterobyte

thanks for your patience pterobyte

i have developed an online registration system that also sends mail messages to the users. it works just fine when running on the web host server that i subscribe to. (i suppose these would be the type that you manage.) but it does not work anymore in my little macbook or my imac running the local sendmail server. it used to before the last os x upgrade.

here is the simple test script called mailtest.php:

<?php
mail ('clarkee@telus.net', 'test', 'test message');
?>

here is the corresponding macbook apache log entry that you asked me to look at:

::1 - - [06/Mar/2009:09:01:38 -0700] "GET /club/mailtest.php HTTP/1.1" 200 321

here are the corresponding macbook mail log entries:

Feb 16 10:00:28 ted-clarkes-imac postfix/master[279]: daemon started -- version 2.4.3, configuration /etc/postfix
Feb 16 10:01:28 ted-clarkes-imac postfix/master[279]: master exit time has arrived

the message does not appear to have been sent nor was it received by the recipient.

i just ran the same test script in my web host server and it worked fine and was received by the recipient.

i still haven't tried changing the logging level in my mac but i will do that. thanks for the information on reporting problems to apple.

Mar 6, 2009 12:11 PM in response to pterobyte

hi again
i am running mac os x client. but i'm using it to run the local apache server and the local sendmail server. i know this is the server forum but others suggested that i try this forum because i couldn't get an answer elsewhere. i was pretty specific in my first posting about what i was running. i am sorry if i wasted your time. you have been helpful. thanks.

Mar 6, 2009 12:28 PM in response to phasorman

Nothing in your first post says you are running client. You are just talking about local services, which are local to the server as well (unless you manage remote services).
It is not only a matter of wasting time, but a matter of not being able to give you the proper advice. Server Admin for example does not exist on Leopard Client.

Anyway, try the following:
sudo postfix start
sudo postfix stop
sudo /bin/launchctl load -w /System/Library/LaunchDaemons/org.postfix.master.plist

Next, try and send mail via your PHP application. If it doesn't work, you should investigate the Apache/PHP side. I have some doubts it is a mail issue.

BTW: The fact that postfix exits after a minute is normal. On client it is configured to run on demand (will fire up when you need it).

Mar 6, 2009 3:55 PM in response to phasorman

i did exactly as you suggested but still no cigar.

here are the apache logs:

::1 - - [06/Mar/2009:16:35:00 -0700] "GET /mailtest.php HTTP/1.1" 404 210
::1 - - [06/Mar/2009:16:35:19 -0700] "GET /club/mailtest.php HTTP/1.1" 200 321
::1 - - [06/Mar/2009:16:40:00 -0700] "GET /club/mailtest.php HTTP/1.1" 200 321

and the mail logs:

Mar 6 16:34:02 ted-clarkes-imac postfix/postfix-script[12416]: starting the Postfix mail system
Mar 6 16:34:02 ted-clarkes-imac postfix/master[12417]: daemon started -- version 2.4.3, configuration /etc/postfix
Mar 6 16:36:28 ted-clarkes-imac postfix/postfix-script[12428]: stopping the Postfix mail system
Mar 6 16:36:28 ted-clarkes-imac postfix/master[12417]: terminating on signal 15

i really have a hard time figuring out why this worked before the os x download and doesn't now. i would like to know if anyone else has experienced this. i feel i shouldn't waste any more of your time. i guess i have to learn some of the terminology like the meaning of local but that's how it was described to me - sorry. i'm leaving the country for 2 weeks and i'll have to wait until then before i can get back at this again. thanks for your time - maybe i'll see you when i get back.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

local sendmail server not working in mac os x 10.5.6

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.