How to setup External Mail server on cPanel Hosting

If you are running your or your clients are running their own private exchange server in the office and need an external mail server set up from the cPanel server pointing to your exchange server then you will need to follow those steps below

Go into WHM / DNS Functions / Edit a DNS Zone
choose the domain > where it says

mail | 14400 | cname |

change to

mail | 14400 | A | ( which is the IP of your customers preferred mail server)

This will point the system to the new mail server !

and then log into your server using  SSH as root

Remove the domain from /etc/localdomains

nano /etc/localdomains

and put the domain into /etc/remotedomains

nano /etc/remotedomains

to find an MX record :

dig MX