Activities

March 2011
M T W T F S S
« Feb   Apr »
 123456
78910111213
14151617181920
21222324252627
28293031  

Disabling email service for a domain in Plesk

Scenario :

Website is hosted on a dedicated server with Plesk installed and email service is hosted somewhere.

Problem :

When we send email to the hosted domain like we have created website domain.tld using plesk and created few account to send email from the dedicated server. We can send email to any outside domains except for our domain( if we send email from the program to xxx@domain.tld, the email owner would not able to receive that mail.

Cause :

Email service will be enabled on the server since the domain.tld has created using plesk and any email sent to this domain routed locally and not been forwarded to internet.

Solution :

1. Correct the DNS entry for MX records in the DNS manager
Go to websites & Domain –>> DNS
I have modified the host record “mail.domain.tld” to my external mail server ip” and updated the MX record accordingly.

2. SSH login to the server and disabled the mail service associated with that domain.
[root@u1454 ~]# /usr/local/psa/bin/domain -u domain.tld -mail_service false SUCCESS: Update of domain ‘domain.tld’ complete.

Great !! That’s it

How to verify my domain email is routed external rather than locally
I’m going to send a mail from the console and verify the mail log to identify the email delivery.

[root@u15320 ~]# echo ” This is a test mail to checking email external routing ” | mail -s “Enabling external mail routing” liju@serveridol.com

Verify the email log,
[root@u15320123 ~]# tail -f /usr/local/psa/var/log/maillog

Mar 16 01:23:02 u15320123 postfix/cleanup[23926]: 11BA5400205: message-id=< 20110316052301.E0620400203@u15323.onlinehome-server.com>
Mar 16 01:23:02 u15320123 postfix/qmgr[17188]: 11BA5400205: from=< root@u153123.onlinehome-server.com>, size=622, nrcpt=1 (queue active)
Mar 16 01:23:02 u15320123 postfix/smtp[23928]: E0620400203: to=< liju@serveridol.com>, relay=127.0.0.1[127.0.0.1]:10027, delay=0.22, delays=0.04/0.02/0.11/0.05, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued as 11BA5400205)
Mar 16 01:23:02 u15320123 postfix/qmgr[17188]: E0620400203: removed
Mar 16 05:23:02 u15320123 postfix/smtpd[23931]: disconnect from unknown[127.0.0.1]
Mar 16 01:23:03 u15320123 postfix/smtp[23928]: 11BA5400205: to=< liju@serveridol.com>, relay=<strong>mx01.1and1.com</strong>[74.208.5.21]:25, delay=0.94, delays=0.05/0/0.06/0.84, dsn=2.0.0, status=sent (250 Message 0MTzZJ-1QQMp41cO1-00QvCa accepted by mxus0.perfora.net)
Mar 16 01:23:03 u15320123 postfix/qmgr[17188]: 11BA5400205: removed

This shows my email is delivered to my smtp server (mx01.1and1.com) 🙂

5 comments to Disabling email service for a domain in Plesk

  • Hello, congratulations for your post, thanks to the’ve solved a major problem, because in my 1and1 dedicated server I have a magento and has to send notifications to an email from 1and1 and if active email service in the sends it to control itself.

    Thanks,

  • Paul Stott

    Hi

    Thanks for this I was tearing my hair trying to work it out cheers

  • Eric

    Thanks you save my day !!!

  • German

    Worked on Plesk 11.5, it’s incredible that there still this kind of bugs… and no options from panel to configure it.

  • Josh

    Thanks!! I went around in circles within the Plesk (11.0) panel, messing with webspaces, subscribers, domains… Just trying to turn off mail services for one domain, inexplicably, is impossible. But this does the trick. Silly to have to resort to SSH for something like this.

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>