using shared host mail server with my VPS server

They have: 426 posts

Joined: Feb 2005

I have two hosting accounts with two separate providers. One is a shared hosting account the other is a VPS.

I use my VPS for video and heavy media stuff and I use some Java applications all of which are not available on a shared hosting account.

While i could install a mail server and / or a DNS server on my VPS, i chose to keep my shared managed hosting for the DNS and mail server as this would relieve me of the head ache of a mail server and DNS server so i can concentrate on application development.

My VPS is running ubuntu 10 and apache2.

My question is simple. How can i configure my VPS to use my shared hosting mail server. I have set up virtual hosts on my VPS and have multiple domains / DNS zones / addon domains in my shared hosting account all with their own email addresses. The A records in my shared account for each domain points to my VPS IP address.

I was thinking I need to specify the MX records in my apache conf file in sites-enabled directory, but I would need to login to my mail server?

Basically, what I need to do is allow my applications on my VPS access to a mail server to send automated emails, like login information.

pr0gr4mm3r's picture

He has: 1,502 posts

Joined: Sep 2006

The MX records are the DNS entries that would be handled on your shared hosting account since that's where your DNS is hosted.

All you should have to do is configure your applications on your VPS to use an external mail server (your shared account). It should be doable on whatever application you are using on your VPS because the email server is frequently separated from the application server.

They have: 426 posts

Joined: Feb 2005

Thanks mate, yes I see how to do it now!!

They have: 1 posts

Joined: Aug 2012


My issue is similar, I have 2 shared hosting accounts, My older 1 processes php very slow, so I had to move to another shared provider, but I have a lot of office mail i need on the old hosting guy, How Do i keep my old email provider the same and just change the Web hosting guy, Is it something i need to do at the domain registar?

{link removed}

He has: 51 posts

Joined: Mar 2012

You can just change the MX entries to point to the other shared host. It's the came concept as the previous solution, except it's Shared to Shared, and not VPS to Shared.

They have: 8 posts

Joined: Dec 2015

Changing MX records of a domain name to your old hosting account will route your mails from old server.

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.