Community discussions

MikroTik App
 
exa
newbie
Topic Author
Posts: 37
Joined: Sat Jul 04, 2009 2:07 pm

some mail problems

Sat Jul 04, 2009 2:19 pm

Hi there,

I came accross a very strange problem with /tool email. When invoked, mikrotik tries to send the mail, but fails, with message "server is not ready".

On the SMTP server (which is properly configured, working and tested, i made this for sure), I see only following error in the postfix log:

(IPs are x'ed)
Jul  4 12:14:59 [postfix/smtpd] connect from unknown[192.168.xxx.xxx]
Jul  4 12:14:59 [postfix/smtpd] disconnect from unknown[192.168.xxx.xxx]
Such behavior seems strange - like mikrotik didn't even try to send the mail. Further investigation lead me to enabling verbose logging on SMTP, which returned that roughly this conversation takes place between mikrotik and smtp:
Jul  3 23:16:19 [postfix/smtpd] > unknown[192.168.xxx.xxx]: 220 xx--mailserver-name-xx
Jul  3 23:16:19 [postfix/smtpd] < unknown[192.168.xxx.xxx]: RSET
Jul  3 23:16:19 [postfix/smtpd] > unknown[192.168.xxx.xxx]: 250 2.0.0 Ok
Jul  3 23:16:19 [postfix/smtpd] < unknown[192.168.xxx.xxx]: QUIT
Jul  3 23:16:19 [postfix/smtpd] > unknown[192.168.xxx.xxx]: 221 2.0.0 Bye
So for me it seems that mikrotik just quits the session and doesn't try to do anything. Notice that this doesn't happen really everytime, just only in like 99.9% cases (which is really bad though) - because of that i'm suspecting some kind of race condition bug in mikrotik SMTP client tool.

Anyway - Has anyone seen this before? If so, is there any known solution?

It would be great if only anyone from mikrotik staff here would be so kind and at least comment on where to try to find the errors. :D

Thanks in advance
exa
 
User avatar
mrz
MikroTik Support
MikroTik Support
Posts: 6043
Joined: Wed Feb 07, 2007 12:45 pm
Location: Latvia
Contact:

Re: some mail problems

Mon Jul 06, 2009 4:49 pm

enable debug logs on router
/system logging add topics=e-mail

what version you are running?
 
exa
newbie
Topic Author
Posts: 37
Joined: Sat Jul 04, 2009 2:07 pm

Re: some mail problems

Mon Jul 06, 2009 9:12 pm

Hm, i finally came to the problem - something just delays the connection for those 20 seconds between the two boxes, so I guess mikrotik just timeouts and then asks the smtp nicely to quit (no idea how the mail sending code is written, but looks like a fair guess doesnt it :D )

the thing between is a machine that also runs smtp redirection, i will try to somehow fix the redirection rule (done with dst-nat now). (Anyone who would know how dst-nat would mess with that..please help ;) )

Anyway, thanks for concern, seems solved, problem is elsewhere.
exa
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8389
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: some mail problems

Wed Jul 08, 2009 12:46 am

(Anyone who would know how dst-nat would mess with that..please help ;) )
you cannot dst-nat to the same subnet =)
Russian-speaking forum: https://forum.mikrotik.by/. Welcome!

For every complex problem, there is a solution that is simple, neat, and wrong.

MikroTik. Your life. Your routing.

Who is online

Users browsing this forum: Google [Bot] and 59 guests