[GLLUG] Sendmail configuration

Mike Rambo mrambo at lsd.k12.mi.us
Thu Mar 20 07:16:18 EDT 2008


Deepan wrote:
> Hi All,
> I am using sendmail via php mail function to send
> emails. However few servers reject my mails with
> the error 'Sender address rejected: Domain not
> found', since mails from my server are sent as
> email at localhost.localdomain. How do I change this
> to a valid domain name ? We only own a public IP.
> we dont really have a domain name, is it possible
> to use IP ? 
> Regards
> Deepan

You need to set up sendmail to masquerade as a real domain, like that of 
your ISP for example, use your ISP as a smart host to send the mail, and 
set up the genericstable feature of sendmail so it will modifiy the mail 
headers to make mail sent by apache (or whatever user your php scripts 
will appear to run as and thus mail as) to be rewritten to a valid user 
from your ISPs perspective. Or at least, those three steps are what I 
have done when I need to do such things. I've got about five or six 
servers set up to do basically what you're describing and It Works For 
Me. That said, I've not spent a great deal of time to see if there is an 
easier way and I certainly don't claim to comprehend all of sendmail. YMMV.


More information about the linux-user mailing list