Sendmail appears to be sending email from php scripts on our server with a from address as "apache@localhost", and hence they are getting bounced by a lot of ISPs.
I think I have the correct settings in php.ini (running on linux by the way) :
[mail function]
; For Win32 only.
SMTP = localhost
; For Win32 only.
sendmail_from = me@mydomain.com
; For Unix only. You may supply arguments as well (default: 'sendmail -t -i').
sendmail_path = /usr/sbin/sendmail
I also changed the following line in sendmail.cf as suggested by one post I found on this board, but no joy :
HReceived🙁from whatever@yourdomain.com)
The bounced emails headers look like :
The original message was received at Wed, 9 Jan 2002 17:04:09 GMT
from apache@localhost
----- The following addresses had permanent fatal errors -----
them@theirdomain.com
(reason: 501 <apache@localhost.localdomain>... Sender domain must exist)
----- Transcript of session follows -----
... while talking to www.theirdomain.com.:
Final-Recipient: RFC822; them@theirdomain.com
Action: failed
Status: 5.5.2
Diagnostic-Code: SMTP; 501 <apache@localhost.localdomain>... Sender domain must exist
Last-Attempt-Date: Wed, 9 Jan 2002 17:04:09 GMT
Return-Path: <apache>
Received: (from me@mydomain.com)
œby localhost.localdomain (8.11.6/8.11.6) id g09H49601813;
Wed, 9 Jan 2002 17:04:09 GMT
Date: Wed, 9 Jan 2002 17:04:09 GMT
Message-Id: <200201091704.g09H49601813@localhost.localdomain>
To: them@theirdomain.com
Subject: The email
From: me@mydomain.com
Reply-To: me@mydomain.com
Any suggestions greatfully received!