To register for an Internet.com membership to receive newsletters and white papers, use the Register button ABOVE.
To participate in the message forums BELOW, click here
I have a website running off a server that I've put together/configured (in linux), and it all seems to be working happily, except for sending emails from the pages.
Sendmail obviously works because I can send test mesages to local and external email addresses. However, if I send an email from a website, it never arrives if I send it to an external address.
I have found a work-around for this, but it is not the ideal solution - I can send it to a local user (eg postmaster), and if there is a .forward file in the users directory then that will send it to the external address. This obviously isn't ideal though, becuse I might want to send the email to one of several different addresses. Does anyone have any helpful suggestions?
What MTA are you using -- sendmail, postfix, qmail, etc.?
Are your Web server and your mail server in agreement about the hostname?
What does the mail error log say?
Based in the info you provided, I'd be looking to see whether the MTA considers your Web mail to be non-local and blocks it as a normal antispam measure.
I'm using sendmail. Where would I find an error log if there is one? I thought if there was an error, then postmaster/root got an email about (I've deliberately generated a couple of those). This certainly isn't doing that.
I don't think sendmail can be considering the web mail as non-local can it, if it will still deliver it to a local adress?
As far as I can tell, the web and mail servers are in agreement about the address (although I don't really know my way about it too well).
Your mail logs are probably in /var/spool/. As root, do this
cd /var/spool/mail
tail -f mail.log
This will continuously monitor the general mail logfile. Now run your PHP mail script on several addresses, internal and external, and see what it has to say.
You're probably running afoul of some sort of sendmail configuration issue. Sendmail is notoriously difficult to administer. That's one of the reasons many distributions have switched to other MTAs, such as Postfix, which are much easier to configure.
hmmm there doesn't appear to be a log file. I'll have a more extensive poke around (logs, configs etc) when I next get a chance to go and actually sit at the computer, instead of dialling in to it with a 56K connection (shared with 3 other people)
Having a simular problem with PHP-Nuke, Sendmail is working but will not masquerade the domain when sending user registration to new users outside of my domain. I am new to PHP so I am at a loss here.
if you're using Apache, the e-mail will always show that it came from something like "apacheuser@hostname.com" unless you specifically alter the headers in your php script.