"Apache Can't Send Mail !"
Document Version: 001b.15-September-2006 Howie Dines
Some php scripts have the ability to send notification emails
to the administrator.
You may find that these emails are not being relayed by sendmail
as the user 'apache' is unknown at host. There seem to be a number
of possible causes with their fixes that can be tried.
In the case of the
comments page on this site, this issue was
fixed using the following script from Brian at www.nuonce.net
The following script, adds "apache" to the virtusertable
# Fix Sendmail not having "apache" in the virtual user table
cd /etc/mail
/bin/cat virtusertable | grep "apache\@" > /dev/null
if [ $? != 0 ]; then
/usr/bin/printf "apache@`hostname`\tadmin" >> /etc/mail/virtusertable
/usr/sbin/makemap hash /etc/mail/virtusertable < virtusertable
fi
The complete thread showing alternative options can be viewed
here.
|