• Inviting everyone who uses WordPress management tools in Plesk
    The Plesk team is conducting a 60-minute research session that includes an interview and a moderated usability test.
    To participate, please use this link .
    Your experience will help shape product decisions and ensure the tools better support real-world use cases.

How to route all email from VPS to foreign server?

M

Mateo1041

Guest
Hello,

We just set up the MX record in Plesk so that all incoming email is routed to another server. This works great for external emails coming in from the outside. But when sending email via PHP on the VPS itself, the emails never arrive.

How can I have the VPS send all email traffic, whether from outside or originating from the server itself to another server for processing?

Do I need to change a sendmail setting somewhere?

Thanks!
- Matt.
 
I think I found the solution to this. I had to remove the domain name from the /var/qmail/rcpthosts and /var/qmail/virtualdomains files.

Now the Plesk VPS no longer thinks it needs to process the emails instead of listening to the MX record which points to a different server.
 
Originally posted by Mateo1041
I think I found the solution to this. I had to remove the domain name from the /var/qmail/rcpthosts and /var/qmail/virtualdomains files.

Now the Plesk VPS no longer thinks it needs to process the emails instead of listening to the MX record which points to a different server.

you could just turn off mail service for each these domains :)
 
Thanks for the reply!

Ok, so use the "Disable" icon under "Mail" in Plesk? That won't affect our PHP scripts sending email from the server will it?
 
yes that wont effect php

Mail service for domain off deleting records in the qmail config and qmail will handle that email address as you need
 
Back
Top