Home > cPanel > Change Email Server IP on cPanel

Step 1: Execute the following command to stop the mail server
/etc/init.d/exim stop

Step 2: Edit the exim configuration file
vi /etc/exim.conf

Find the following section from the file:
driver = smtp
interface = ${if exists {/etc/mailips}{${lookup{$sender_address_domain}lsearch{/etc/mailips}{$value}{}}}{}}
helo_data = ${if exists {/etc/mailhelo}{${lookup{$sender_address_domain}lsearch{/etc/mailhelo}{$value}{$primary_hostname}}}{$primary_ho stname}}

Edit the above lines into (where x.x.x.x is your ip):
driver = smtp
interface = x.x.x.x

Step 3: Make the configuration file read-only so that it won't be reset automatically
chattr +aui /etc/exim.conf

Step 4: Start the exim server
/etc/init.d/exim start

Flag Counter