Mail Forwarding Rule "Connection Reset"

Discuss the Scalix Server software

Moderators: ScalixSupport, admin

jonny
Posts: 39
Joined: Wed Mar 22, 2006 1:25 pm

Mail Forwarding Rule "Connection Reset"

Postby jonny » Tue Jul 25, 2006 1:09 pm

I have updated this thread, please see my post below:
Last edited by jonny on Wed Jul 26, 2006 5:18 am, edited 1 time in total.

jonny
Posts: 39
Joined: Wed Mar 22, 2006 1:25 pm

Postby jonny » Wed Jul 26, 2006 5:17 am

Aha - okay, the plot thickens, let me give some more detail!

So, we are migrating from our hosted Exchange to an in house Scalix solution - we are still in the testing stage, so what I need, before I flip the MX Records for our domain to point to the Scalix Server, is a way for users to still access their email in the hosted exchange.

The solution I am proposing is to set up a redirect rule on each users email so email gets punted out from scalix to the hosted exchange, eg:

Code: Select all

sxaa --user "Tommy Test" --redirect tommy.test@exchange.hosted.com --retain


This works great most of the time (oh if only life were that simple) - however, one email account, yahoo.com causes a problem - email does not get redirected and gets stuck in the mailq:

Code: Select all

[root@mail]# mailq
                /var/spool/mqueue (1 request)
-----Q-ID----- --Size-- -----Q-Time----- ------------Sender/Recipient-----------
k6Q8sbcx010443      209 Wed Jul 26 09:54 <myyahooaccount@yahoo.com>
                 (reply: read error from mx00.hosted.com.)
                                         <tommy.test@exchange.hosted.com>
                Total requests: 1


Now to test and do a bit of debugging, I changed the above SXAA rule to be a forward instead:

Code: Select all

sxaa --user "Tommy Test" --forward tommy.test@exchange.hosted.com


And lo-and-behold this works - although the message is attached, not inline, which my users aren't going to be happy about.

With the yahoo "redirect" mail, stuck in the mail queue, I issued a sendmail -q -v to see the verbose output:

Code: Select all

[root@mail ccijohn]# sendmail -q -v
-- Sendmail Verbose Output --

Running /var/spool/mqueue/k6QB6fxw012051 (sequence 1 of 1)

--deliver, id=k6QB6fxw012051, mailer=esmtp, host=`exchange.hosted.com.', first user=`tommy.test@exchange.hosted.com'
remotename(<myyahooaccount@yahoo.com>)
remotename => `myyahooaccount@yahoo.com'

send to 0x816678c=<tommy.test@exchange.hosted.com>:
        mailer 4 (esmtp), host `exchange.hosted.com.'
        user `tommy.test@exchange.hosted.com', ruser `<null>'
        state=OK, next=0x0, alias 0x0, uid 0, gid 0
        flags=80000382<QPRIMARY,QPINGONFAILURE,QPINGONDELAY,QHASNOTIFY,QRCPTOK>
        owner=(none), home="(none)", fullname="(none)"
        orcpt="(none)", statmta=(none), status=(none)
        finalrcpt="RFC822; tommy.test@exchange.hosted.com"
        rstatus="(none)"
        statdate=(none)
ctladdr=[NULL]
openmailer: TCP exchange.hosted.com.
<tommy.test@exchange.hosted.com>... Connecting to mx01.hosted.com. via esmtp...
220 ************************************************************
>>> EHLO mail.core-control.net
250-mxeu5.kundenserver.de pleased to meet you
250-PIPELINING
250-8BITMIME
250-SIZE 52428800
250 XXXA
openmailer: MCI@0x8171bbc: flags=4006c<CACHED,ESMTP,SIZE,8BITMIME,PIPELINED>,
        errno=0, herrno=0, exitstat=0, state=2, pid=0,
        maxsize=52428800, phase=client EHLO, mailer=esmtp,
        status=(null), rstatus=(null),
        host=mx01.hosted.com., lastuse=Thu Jul 27 09:07:54 2006

>>> MAIL From:<myyahooaccount@yahoo.com> SIZE=1708
250 mail from: <myyahooaccount@yahoo.com> ok
>>> RCPT To:<tommy.test@exchange.hosted.com>
>>> DATA
250 <tommy.test@exchange.hosted.com> ok
354 Enter mail, end with "." on a line by itself
remotename(John Reeves <myyahooaccount@yahoo.com>)
remotename => `John Reeves <myyahooaccount@yahoo.com>'
remotename("John Reeves" <tommy.test@ourscalixserver.com>)
remotename => `"John Reeves" <tommy.test@ourscalixserver.com>'
>>> .
<tommy.test@exchange.hosted.com>... Connecting to mx00.hosted.com. via esmtp...
<tommy.test@exchange.hosted.com>... Closing connection to mx01.hosted.com.
220 ************************************************************
>>> EHLO mail.core-control.net
250-mxeu0.kundenserver.de pleased to meet you
250-PIPELINING
250-8BITMIME
250-SIZE 52428800
250 XXXA
openmailer: MCI@0x81739cc: flags=4006c<CACHED,ESMTP,SIZE,8BITMIME,PIPELINED>,
        errno=0, herrno=0, exitstat=0, state=2, pid=0,
        maxsize=52428800, phase=client EHLO, mailer=esmtp,
        status=(null), rstatus=(null),
        host=mx00.hosted.com., lastuse=Thu Jul 27 09:07:54 2006

>>> MAIL From:<myyahooaccount@yahoo.com> SIZE=1708
250 mail from: <myyahooaccount@yahoo.com> ok
>>> RCPT To:<tommy.test@exchange.hosted.com>
>>> DATA
250 <tommy.test@exchange.hosted.com> ok
354 Enter mail, end with "." on a line by itself
remotename(John Reeves <myyahooaccount@yahoo.com>)
remotename => `John Reeves <myyahooaccount@yahoo.com>'
remotename("John Reeves" <tommy.test@ourscalixserver.com>)
remotename => `"John Reeves" <tommy.test@ourscalixserver.com>'
>>> .
<tommy.test@exchange.hosted.com>... Deferred: Connection reset by mx00.hosted.com.
giveresponse: status=75, dsn=4.0.0, e->e_message=reply: read error from mx01.hosted.com., errnum=104
remotename(John Reeves <myyahooaccount@yahoo.com>)
remotename("John Reeves" <tommy.test@ourscalixserver.com>)
Closing connection to mx00.hosted.com.


And this is where I become slightly stumped - it looks like it should be working, but alas no - has anyone got any ideas on this one? It looks to me like Sendmail is not inserting any message data once it has connected to the Hosted Exchange's SMTP server....

Thanks in advance.
Jonny.
Last edited by jonny on Thu Jul 27, 2006 4:24 am, edited 1 time in total.

jonny
Posts: 39
Joined: Wed Mar 22, 2006 1:25 pm

Postby jonny » Wed Jul 26, 2006 7:21 am

I turned on logging in /var/opt/scalix/sys/smtpd.conf and recieved this out in /var/opt/scalix/tmp/smtpd.log

Code: Select all

SMTP Relay 10.0.1.3 started (11906): Wed, 26 Jul 2006 12:05:14 +0100 (BST)
Accepted client 1 from  (web55704.mail.re3.yahoo.com)
Cli 11906/1 sent  : 220 mail.ourscalixserver.net ESMTP Scalix SMTP Relay 10.0.1.3; Wed, 26 Jul 2006 12:06:40 +0$

Cli 11906/1 rcvd: 'HELO web55704.mail.re3.yahoo.com'
Cli 11906/1 sent  : 250 mail.ourscalixserver.net Hello web55704.mail.re3.yahoo.com [216.252.110.35], pleased to$

Cli 11906/1 rcvd: 'MAIL FROM:<myyahooaccount@yahoo.com>'
Cli 11906/1 sent  : 250 myyahooaccount@yahoo.com... Sender ok

Cli 11906/1 rcvd: 'RCPT TO:<tommy.test@ourscalixserver.net>'
  ... new process 12034
11906: Allocate new unix.in process 12034
Cli 11906/1 rcvd U: '220 Scalix ESMTP Ready.'
Cli 11906/1 rcvd U: '250 Ok'
Cli 11906/1 sent U: rcpt to: <tommy.test@ourscalixserver.net>

Cli 11906/1 rcvd U: '250 Ok'
Cli 11906/1 sent  : 250 Ok

Cli 11906/1 rcvd: 'DATA'
Cli 11906/1 sent  : 354 Enter mail, end with "." on a line by itself (relay)

Cli 11906/1 sent U: data

Cli 11906/1 rcvd U: '354 Enter mail, end with "." on a line by itself.'
Cli 11906/1 sent U: Received: from web55704.mail.re3.yahoo.com (web55704.mail.re3.yahoo.com 216.252.110.35)
            by mail.ourscalixserver.net (Scalix SMTP Relay 10.0.1.3)
            via ESMTP; Wed, 26 Jul 2006 12:06:41 +0100 (BST)
        Received: (qmail 61213 invoked by uid 60001); 26 Jul 2006 11:13:04 -0000
        DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws;
          s=s1024; d=yahoo.com;
          h=Message-ID:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding;
          b=bVKKZRfHv7wBv5QxVMlarJo7VT3609rF/yOmhPv9/L/q5ANO7T8OBKZ6VacgdXQ0C7xvJUiHviKg+auD4fQPO8S4+0lySXWd$
        Message-ID: <20060726111304.61209.qmail@web55704.mail.re3.yahoo.com>
        Received: from [87.74.0.40] by web55704.mail.re3.yahoo.com via HTTP; Wed, 26 Jul 2006 04:13:04 PDT
        Date: Wed, 26 Jul 2006 04:13:04 -0700 (PDT)
        From: John Reeves <myyahooaccount@yahoo.com>
        Subject: Another Test of the SMTPD Logging
        To: tommy.test@ourscalixserver.net
        MIME-Version: 1.0
        Content-Type: text/plain; charset=iso-8859-1
        Content-Transfer-Encoding: 8bit

        This one will get stuck! :) again

        __________________________________________________
        Do You Yahoo!?

Cli 11906/1 got .
Cli 11906/1 sent U: Tired of spam?  Yahoo! Mail has the best spam protection around
        http://mail.yahoo.com
        .

Cli 11906/1 rcvd U: '250 Ok'
Cli 11906/1: Submitted message ': <20060726111304.61209.qmail@web55704.mail.re3.yahoo.com>' to unix.in.
        response: '250 Ok'
Cli 11906/1 Finished submitting msg  : <20060726111304.61209.qmail@web55704.mail.re3.yahoo.com>
Cli 11906/1 sent  : 250 Ok

Cli 11906/1 rcvd: 'QUIT'
Cli 11906/1 sent  : 221 mail.ourscalixserver.net closing connection


So it would appear no problem there when recieving the message. Which log should I be checking for the outgoing messages?

jonny
Posts: 39
Joined: Wed Mar 22, 2006 1:25 pm

Postby jonny » Wed Jul 26, 2006 7:40 am

If I manually telnet the the MX I can send email to it - so why is Scalix failing :(

Code: Select all

[root@mail sysconfig]# telnet mx01.hosted.com 25
Trying XXX.227.XX.186...
Connected to mx01.hosted.com (XXX.227.XX.186).
Escape character is '^]'.
220 *************************************************************
EHLO mail.ourscalixserver.net
250-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXA
250-PIPELINING
250-8BITMIME
250-SIZE 52428800
250 XXXB
MAIL From:<myyahooaccount@yahoo.com> SIZE=1708
250 mail from: <myyahooaccount@yahoo.com> ok
RCPT To:<tommy.test@exchange.hosted.com>
250 <tommy.test@exchange.hosted.com> ok
DATA
354 Enter mail, end with "." on a line by itself
Hi There!
.
250 Message 0MKuA8-1G5hgq1nPZ-0005Vy accepted by mxeu11.hosted.com
^]
telnet>


Return to “Scalix Server”



Who is online

Users browsing this forum: No registered users and 1 guest