Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My setup :

Our current server [example] which is containing domain testdom.com.

testdom.com's MX record points to Google mail. Due to some issues we need to host our domain on some other server [example], so I'm setting up environment for testdom.com on Once I complete my setup, I can point our A record from the current server to the new one.

I've created domain with plesk testdom.com on, all is working fine, My issue with sending mail by php function. I can send mail to all domains, but my own domain!

eg from: admin@testdom.com to support@testdom.com

When I googled all said about mydestination. In mycase it's

 mydestination = localhost.$mydomain, localhost, localhost.localdomain

Please help me solve this issue, as I need this to switch to my new server.

Versions :

Operating System : CentOS 6.4
Send Mail        : Postfix-2.8.4
PHP              : PHP 5.3.3
Plesk            : 10.4.4
domain           : testdom.com // example
share|improve this question
please do not use existing domain names for examples. use example.com instead. also consider using one of the IP-addresses reserved for testing purposes (as outlined in RFC5737) – umläute Oct 22 '13 at 9:37
try sending an email from the cmdline (echo "foo" | mail -s testmail support@example.com) do you get any errors? what do the postfix logs say? – umläute Oct 22 '13 at 9:44
@umläute, I can able to send mails with my current settings to all email addresses, other than <anything>@testdom.com – Kumar Oct 22 '13 at 9:55
@umläute, I mean, from: <anything>@testdom.com - to: <anything>@<anthing>.com = working – Kumar Oct 22 '13 at 9:56
from: <anything>@<anthing>.com - to: <anything>@testdom.com = not working – Kumar Oct 22 '13 at 9:56

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.