Results 1 to 3 of 3

Thread: Adding RelayMTA, per Wiki instructions, no longer sends -- "Connection timed out"

  1. #1
    pgn
    pgn is offline Junior Member
    Join Date
    Jun 2010
    Posts
    7
    Rep Power
    5

    Question Adding RelayMTA, per Wiki instructions, no longer sends -- "Connection timed out"

    I'm migrating to a new Zimbra server.

    The old server (CommunigatePro;same, lan -- one box over ...) is setup to use an outbound SMTP smarthost:

    mail.messagingengine.com:587

    It's a trivial setup -- enter one field in the AdminGUI, click SAVE. Done. Auth'ing with USERNAME:PASSWORD, it works great, as expected.

    Now, I'm trying to setup the Zimbra box to use the same SMTP smarthost.

    So far, I've been unable to 'convice' Zimbra & the SmartHost to 'play nice' ... any suggestions would be appreciated!

    Here's what I've sone so far:

    Following instructions at,

    SMTP Relay
    The Penguinlinux.com Blog Zimbra smtp relay through smart host smtp-auth
    Outgoing SMTP Authentication - Zimbra :: Wiki

    I've setup for SmartHost usage,
    Code:
    	rm /opt/zimbra/conf/relay_password*
    	su - zimbra
    	zmprov ms my.domain.com zimbraMtaRelayHost mail.messagingengine.com:587
    
    	echo mail.messagingengine.com USERNAME:PASSWORD > /opt/zimbra/conf/relay_password
    	/opt/zimbra/postfix-2.6.5.2z/sbin/postmap hash:/opt/zimbra/conf/relay_password
    
    	/opt/zimbra/postfix-2.6.5.2z/sbin/postmap -q mail.messagingengine.com /opt/zimbra/conf/relay_password
    		USERNAME:PASSWORD
    
    	postconf -e smtp_sasl_auth_enable=yes
    	postconf -e smtp_sasl_password_maps=hash:/opt/zimbra/conf/relay_password
    	postconf -e smtp_use_tls=yes
    	postconf -e smtp_tls_security_level=encrypt
    	postconf -e smtp_sasl_mechanism_filter=plain
    	postconf -e smtp_sasl_security_options=noanonymous
    	postconf -e smtp_cname_overrides_servername=no
    
    	zmlocalconfig -e postfix_smtp_sasl_auth_enable=yes
    	zmlocalconfig -e postfix_smtp_sasl_password_maps=hash:/opt/zimbra/conf/relay_password
    	zmlocalconfig -e postfix_smtp_use_tls=yes
    	zmlocalconfig -e postfix_smtp_tls_security_level=encrypt
    	zmlocalconfig -e postfix_smtp_sasl_mechanism_filter=plain
    	zmlocalconfig -e postfix_smtp_sasl_security_options=noanonymous
    	zmlocalconfig -e postfix_smtp_cname_overrides_servername=no
    
    	exit
    then, in Admin GUI, I DISABLE RelayMTA, and,

    Code:
    	su - zimbra
    	zmcontrol stop
    	zmcontrol start
    	postfix reload
    then, send from the webUI to "my.acct@sbcglobal.net":

    Code:
    	tail -f /var/log/zimbra.log
    		Jun  7 15:29:44 mail postfix/smtpd[29002]: connect from my.domain.com[127.0.0.2]
    		Jun  7 15:29:44 mail postfix/smtpd[29002]: 6CE98160183: client=my.domain.com[127.0.0.2]
    		Jun  7 15:29:44 mail postfix/cleanup[29018]: 6CE98160183: message-id=<348475748.0.1275949783883.JavaMail.root@my.domain.com>
    		Jun  7 15:29:44 mail postfix/smtpd[29002]: disconnect from my.domain.com[127.0.0.2]
    		Jun  7 15:29:44 mail postfix/qmgr[19134]: 6CE98160183: from=<testacct@my.domain.com>, size=676, nrcpt=1 (queue active)
    		Jun  7 15:29:44 mail amavis[16416]: (16416-01) ESMTP::10024 /opt/zimbra/data/amavisd/tmp/amavis-20100607T152944-16416: <testacct@my.domain.com> -> <my.acct@sbcglobal.net> SIZE=676 Received: from my.domain.com ([127.0.0.1]) by localhost (my.domain.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP for <my.acct@sbcglobal.net>; Mon,  7 Jun 2010 15:29:44 -0700 (PDT)
    		Jun  7 15:29:44 mail amavis[16416]: (16416-01) Checking: L81hhvOQf3r9 MYNETS [127.0.0.2] <testacct@my.domain.com> -> <my.acct@sbcglobal.net>
    		Jun  7 15:29:44 mail postfix/smtpd[29068]: connect from localhost.localdomain[127.0.0.1]
    		Jun  7 15:29:44 mail postfix/smtpd[29068]: D4D19160184: client=localhost.localdomain[127.0.0.1]
    		Jun  7 15:29:44 mail postfix/cleanup[29018]: D4D19160184: message-id=<348475748.0.1275949783883.JavaMail.root@my.domain.com>
    		Jun  7 15:29:44 mail postfix/qmgr[19134]: D4D19160184: from=<testacct@my.domain.com>, size=1172, nrcpt=1 (queue active)
    		Jun  7 15:29:44 mail amavis[16416]: (16416-01) FWD via SMTP: <testacct@my.domain.com> -> <my.acct@sbcglobal.net>,BODY=7BIT 250 2.0.0 Ok, id=16416-01, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as D4D19160184
    		Jun  7 15:29:44 mail amavis[16416]: (16416-01) Passed CLEAN, MYNETS LOCAL [127.0.0.2] [127.0.0.2] <testacct@my.domain.com> -> <my.acct@sbcglobal.net>, Message-ID: <348475748.0.1275949783883.JavaMail.root@my.domain.com>, mail_id: L81hhvOQf3r9, Hits: -1.633, size: 676, queued_as: D4D19160184, 447 ms
    		Jun  7 15:29:44 mail postfix/smtp[29025]: 6CE98160183: to=<my.acct@sbcglobal.net>, relay=127.0.0.1[127.0.0.1]:10024, delay=0.53, delays=0.05/0.03/0.01/0.44, dsn=2.0.0, status=sent (250 2.0.0 Ok, id=16416-01, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as D4D19160184)
    		Jun  7 15:29:44 mail postfix/qmgr[19134]: 6CE98160183: removed
    		Jun  7 15:29:44 mail amavis[16416]: (16416-01) extra modules loaded: /opt/zimbra/zimbramon/lib/x86_64-linux-thread-multi/auto/Net/SSLeay/autosplit.ix, /opt/zimbra/zimbramon/lib/x86_64-linux-thread-multi/auto/Net/SSLeay/randomize.al, IO/Socket/SSL.pm, Net/LDAP/Extension.pm, Net/SSLeay.pm
    		Jun  7 15:29:47 mail postfix/smtp[29078]: D4D19160184: to=<my.acct@sbcglobal.net>, relay=sbcmx9.prodigy.net[207.115.37.23]:25, delay=2.5, delays=0.11/0.03/1.5/0.81, dsn=2.0.0, status=sent (250 2.0.0 o57MTkW9015367 Message accepted for delivery)
    		Jun  7 15:29:47 mail postfix/qmgr[19134]: D4D19160184: removed
    		Jun  7 15:30:02 mail zimbramon[32138]: 32138:info: 2010-06-07 15:30:02, QUEUE: 0 0
    		Jun  7 15:30:06 mail zmmailboxdmgr[1010]: status requested
    		Jun  7 15:30:06 mail zmmailboxdmgr[1010]: status OK
    message is successfully delivered/received @ "my.acct@sbcglobal.net".

    Next, I *EN*ABLE RelayMTA in Admin GUI, and,

    Code:
    	su - zimbra
    	zmcontrol stop
    	zmcontrol start
    	postfix reload
    then, again, send to "my.acct@sbcglobal.net". This time,

    Code:
    	tail -f /var/log/zimbra.log
    		Jun  7 15:42:58 mail postfix/smtpd[3378]: connect from my.domain.com[127.0.0.2]
    		Jun  7 15:42:58 mail postfix/smtpd[3378]: 87DEB160124: client=my.domain.com[127.0.0.2]
    		Jun  7 15:42:58 mail postfix/cleanup[3382]: 87DEB160124: message-id=<1560766941.0.1275950577988.JavaMail.root@my.domain.com>
    		Jun  7 15:42:58 mail postfix/smtpd[3378]: disconnect from my.domain.com[127.0.0.2]
    		Jun  7 15:42:58 mail postfix/qmgr[3383]: 87DEB160124: from=<testacct@my.domain.com>, size=677, nrcpt=1 (queue active)
    		Jun  7 15:42:58 mail amavis[30566]: (30566-01) ESMTP::10024 /opt/zimbra/data/amavisd/tmp/amavis-20100607T154258-30566: <testacct@my.domain.com> -> <my.acct@sbcglobal.net> SIZE=677 Received: from my.domain.com ([127.0.0.1]) by localhost (my.domain.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP for <my.acct@sbcglobal.net>; Mon,  7 Jun 2010 15:42:58 -0700 (PDT)
    		Jun  7 15:42:58 mail amavis[30566]: (30566-01) Checking: 9MQZKFczyl97 MYNETS [127.0.0.2] <testacct@my.domain.com> -> <my.acct@sbcglobal.net>
    		Jun  7 15:42:58 mail postfix/smtpd[3387]: connect from localhost.localdomain[127.0.0.1]
    		Jun  7 15:42:58 mail postfix/smtpd[3387]: EF287160184: client=localhost.localdomain[127.0.0.1]
    		Jun  7 15:42:58 mail postfix/cleanup[3382]: EF287160184: message-id=<1560766941.0.1275950577988.JavaMail.root@my.domain.com>
    		Jun  7 15:42:59 mail postfix/qmgr[3383]: EF287160184: from=<testacct@my.domain.com>, size=1173, nrcpt=1 (queue active)
    		Jun  7 15:42:59 mail amavis[30566]: (30566-01) FWD via SMTP: <testacct@my.domain.com> -> <my.acct@sbcglobal.net>,BODY=7BIT 250 2.0.0 Ok, id=30566-01, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as EF287160184
    		Jun  7 15:42:59 mail amavis[30566]: (30566-01) Passed CLEAN, MYNETS LOCAL [127.0.0.2] [127.0.0.2] <testacct@my.domain.com> -> <my.acct@sbcglobal.net>, Message-ID: <1560766941.0.1275950577988.JavaMail.root@my.domain.com>, mail_id: 9MQZKFczyl97, Hits: -1.706, size: 677, queued_as: EF287160184, 385 ms
    		Jun  7 15:42:59 mail postfix/smtp[3384]: 87DEB160124: to=<my.acct@sbcglobal.net>, relay=127.0.0.1[127.0.0.1]:10024, delay=0.52, delays=0.1/0.01/0.01/0.38, dsn=2.0.0, status=sent (250 2.0.0 Ok, id=30566-01, from MTA([127.0.0.1]:10025): 250 2.0.0 Ok: queued as EF287160184)
    		Jun  7 15:42:59 mail postfix/qmgr[3383]: 87DEB160124: removed
    		Jun  7 15:42:59 mail amavis[30566]: (30566-01) extra modules loaded: /opt/zimbra/zimbramon/lib/x86_64-linux-thread-multi/auto/Net/SSLeay/autosplit.ix, /opt/zimbra/zimbramon/lib/x86_64-linux-thread-multi/auto/Net/SSLeay/randomize.al, IO/Socket/SSL.pm, Net/LDAP/Extension.pm, Net/SSLeay.pm
    		Jun  7 15:43:29 mail postfix/smtp[3389]: connect to in1.smtp.messagingengine.com[66.111.4.75]:587: Connection timed out
    the message is never delivered. Note the

    Code:
    		Jun  7 15:43:29 mail postfix/smtp[3389]: connect to in1.smtp.messagingengine.com[66.111.4.75]:587: Connection timed out
    response from the smarthost.

    What else needs to be configured/changed to get Zimbra/Postfix to use the smarthost?

  2. #2
    pgn
    pgn is offline Junior Member
    Join Date
    Jun 2010
    Posts
    7
    Rep Power
    5

    Default

    There seem to be two issues 'in the way' here.

    (1) The smarthost I use, fastmail.fm, requires smarthost address, (relayhost=... in /opt/zimbra/postfix/conf/main.cf) to work (cref: http://wiki.fastmail.fm/index.php?ti...ix#Basic_Setup)

    (2) Zimbra's AdminUI does NOT accept brackets in the RelayMTA field.

    If I try to enter, "[mail.messaging.engine]", it complains "Value did not match valid values.", and the "Save" button remains greyed out & inactive.

    Either there's an escape sequence required to pass those "[]", or it's a bug in the Form validation parsing,

    Atm, manual entry seems to be the only way available ...

    unfortunately, I can't seem to get the changes to stick.

    if I
    Code:
    postconf -e relayhost=[mail.messagingengine.com]:587
    postfix reload
    the change to main.cf is immediately made, and smarthost works. BUT, the changes don't persist across server restart. After restart, the value in main.cf is rewritten to whatever's been last successfully etered in the AdminUI -- either (empty), or something withOUT brackets ...

    reading,

    "Persistence across Zimbra restarts"
    Outgoing SMTP Authentication - Zimbra :: Wiki

    If I instead try,
    Code:
    zmlocalconfig -e postfix_relayhost=mail.messagingengine.com:587
    zmcontrol stop && zmcontrol start
    the change DOES persist across restart, but, of course, I'm missing the brackets.

    If I try
    Code:
    zmlocalconfig -e postfix_relayhost=[mail.messagingengine.com]:587
    zmcontrol stop && zmcontrol start
    then, after restart, I'm back to (empty) or last OK entry from AdminUI again.

    seems that zimbra does not like brackets EITHER in the AdminUI, or in the zmlocalconfig parser ...

  3. #3
    pgn
    pgn is offline Junior Member
    Join Date
    Jun 2010
    Posts
    7
    Rep Power
    5

    Default

    (1) the smarthost, @ fastmail.fm, apparently requires the RelayMTA spec'n in the following format:

    relayhost = [mail.messagingengine.com]

    including the brackets.

    (cref: http://wiki.fastmail.fm/index.php?ti...iguringPostfix)

    (2) Zimbra's AdminUI won't accept brackets in the Field.

    (3) manual intervention with,

    Code:
    zmprov mcf zimbraMtaRelayHost [mail.messagingengine.com]:587
    zmcontrol stop
    zmcontrol start
    grep relayhost /opt/zimbra/postfix/conf/main.cf
    	relayhost = [mail.messagingengine.com]:587
    seems to workaround successfully.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. migrate20070809-Signatures.pl?
    By j.mc in forum Installation
    Replies: 4
    Last Post: 06-11-2008, 09:52 AM
  2. Replies: 13
    Last Post: 07-20-2007, 03:21 AM
  3. Is it started or not
    By kwelipatton in forum Installation
    Replies: 10
    Last Post: 03-28-2006, 11:11 PM
  4. Replies: 18
    Last Post: 10-30-2005, 09:12 PM
  5. Certify Error on (re)install
    By rodrigoccurvo in forum Installation
    Replies: 4
    Last Post: 09-23-2005, 09:04 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •