• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Set Plesk as backup mailserver

T

teren

Guest
Hi, has anyone ever successfully setup a domain on Plesk to be a backup mail server? I have multiple plesk servers and would like to create some redundancy, I have the dns records all setup. All that I really need to know how to do is to setup qmail to forward everything to the master mail server. Can somebody tell me what files I have to edit? I remember seeing a post once about this but I couldn't find it. Thanks

Teren
 
Hi Teren,

Plesk can't do good as secondary / backup MX server.

But, you can order IP and setup on that IP new mail server (qmail, postfix, sendmail, whatever...) and use it as secondary MX. Of course you will not bind Plesk on that new iP.

We are doing this for our clients with great success.

Good luck.
 
Thanks for the fast reply. What exactly do you mean by order a new IP? Do you mean just setup another box and just have that be a dedicated backup mail server? Thanks
 
You can use the Plesk box as a backup MX. Disable mail within Plesk for that domain. Go to /var/qmail/control and add the domain to morercpthosts, run /usr/bin/qmail-newmrh to generate morercpthosts binary, then create a file called smtproutes with the following contents:

domain.com:111.111.111.111

Where domain.com is the domain you want backup MX for, and 111.111.111.111 is the IP.

EDIT: You only need to add the domain in Plesk if you're using it for anything else - for backup MX only skip the "disable mail for that domain" bit.

HTH
 
rcpthost file would be re-written when mungling with new/exsiting domain names, upgrades, ... thus this solution is not good

The only way to setup (and forget) backup MX on Plesk server is to order additional IP address and bind on it new MTA. Clean, nice and easy.
 
I meant morercpthosts, wasn't thinking straight sorry - mchk doesn't overwrite this or smtproutes. Post above edited.
 
Thanks!

Cranky,

Thanks for your solution, it was exactly what I was looking for. I managed to implement my Plesk server as a Backup MX by using morercpthosts and MX records in the DNS.

Best wishes,
Steve
 
I need to do the same and want to make sure I have impletmented this correctly.

In my case, I am hosting the web site under plesk and the DNS. The mail is being sent to a remote mail server. DNS is setup for that.

Here is my DNS record:

polknc.org. NS ns1.synergydns.net.
ns.polknc.org. A 207.97.214.168
polknc.org. A 207.97.214.168
webmail.polknc.org. A 207.97.214.168
mail.polknc.org. A 216.105.135.226
backupmail.polknc.org. A 207.97.214.168
ftp.polknc.org. CNAME polknc.org.
lists.polknc.org. CNAME polknc.org.
www.polknc.org. CNAME polknc.org.
polknc.org. MX (50) backupmail.polknc.org.
polknc.org. MX (10) mail.polknc.org.
207.97.214.168 / 24 PTR polknc.org.

Currently the domain polknc.org is in my rcpthosts and virtualdomains files in /var/qmail/control directory.

Should I remove the domain from those files?

Here is my morercpthosts file:

polknc.org

Here is my smtproutes file:

polknc.org: 216.105.135.226

Is this the correct setup?

Thanks
 
As I understand it:
You should disable mail completely in Plesk for that domain. Plesk will therefore remove it from control/rcpthosts and control/virtualdomains

You should keep it in morercpthosts (as you've done already).
Then run /usr/bin/qmail-newmrh as somebody already said

As your DNS is set up, smtproutes aren't necessary.

I used this configuration several times for myself already, seems to work.

Best wishes,
Steve
 
Thanks.

In the past I was catching all of the mail on the backup server in a "catchall" account. I now have a mailbox full of messages. The client was supposed to be checking the mailbox periodically but hasn't.

Is there an easy way to now forward all of that on to the main mail server?
 
Set up two IMAP accounts in Outlook Express, and drag the mails from one to the other.

or

Move the physical mail files to the new server, and make sure they have the right user / group ownership (just make it the same as the rest of the emails in that directory).

cheers
 
A question from this side related to fallback mail:

If I buy a server and install only the OS (let's say Debian Sarge). Then set a clean Qmail installation on it and add the domains where I want to be fallback mail for in /var/qmail/control/rcpthosts and add in the nameservers of that domain MX 20 with the hostname from my fallback mailserver.

A'm I doing that on the right way or...?
 
Originally posted by steviemcg
As I understand it:
You should disable mail completely in Plesk for that domain. Plesk will therefore remove it from control/rcpthosts and control/virtualdomains

You should keep it in morercpthosts (as you've done already).
Then run /usr/bin/qmail-newmrh as somebody already said

As your DNS is set up, smtproutes aren't necessary.

Steve

So if I want to use my Plesk server as a seconday MX for a domain or DNS which is not hosted with me then do I just need to add the domain to my morercpthosts and run qmail-newmrh.

ie DNS records for domain.com (DNS records not on my box)

domain.com 111.111.111.111
mail.domain.com 111.111.111.111
mail2.domain.com 222.222.222.222 (which is me)

I add to morercpthosts
domain.com

is it that simple or do I need to add
domain.com:111.111.111.111

Roo
 
Back
Top