PHP/mail : server sends email originating from wrong domain
Posted
by Niro
on Server Fault
See other posts from Server Fault
or by Niro
Published on 2010-05-09T15:29:45Z
Indexed on
2010/05/09
15:38 UTC
Read the original article
Hit count: 288
I have a Mediatemple dv (Plesk) server with two domains, each has static IP.
I had domain1 as main domain and domain2 as secondary.
When A PHP script from domain2 sends email the headers show the IP address of domain1 as the origin. Received: from domain2.com (domain1.com [70.ipof domain1]).
I want only domain2 to be mentioned so I did the following:
Changed server name to domain2.com made domain2.com the primary domain (about 30 hours ago) made fixed IP address of domain2.com the default address for the server.
Still when the script sends emails I see the same info as above in the header.
What do I need to do to make the email origin domain2.com?
© Server Fault or respective owner