- Plesk Onyx for Linux
How to configure Qmail server send outgoing messages thought relay?
Plesk does not support configuring relay options in Qmail. Vote to implement possibility to configure relayhost in Plesk Uservoice portal. Top-ranked suggestions is likely to be implemented in new product versions.
Relay can be configured by modifying Qmail configuration files directly on the server.
NOTE: Such customization was not tested and is not officially supported by Plesk, so perform it at your own risk.
NOTE: Any customization made in Qmail configuration can be overwritten by Plesk Update (for example, in case of bug fix, when configuration files are updates), Plesk Upgrade or by
mchk utility, which resets default mail server configuration.
Connect to the server via SSH;
Make sure the domain is listed in
/var/qmail/control/rcpthosts. This configures Qmail to accept mail for the domain:
# cat /var/qmail/control/rcpthosts
Create the SMTP routes for the domain to the new server in
To relay email for a specific
domain.comto another mail server, create the line:
To relay all email to another mail server, regardless of the destination domain, create this line:
Here's a working configuration example where all mail to
example1.comis relayed via
relay-mail-server.com. Mail to
example2.comis relayed via
relay2-mail-server.comand all other domains mail is relayed via
# cat /var/qmail/control/smtproutes
# service xinetd restart