Menu

exception socket closed

Help
xtrmxtrm
2015-10-02
2015-10-25
  • xtrmxtrm

    xtrmxtrm - 2015-10-02

    Hi, Im getting incoming server socket closed error everytime I try to add my Exchange account to Thunderbird, please help.
    My system is Ubuntu 14.0.4 and ThunderBird lastest version. Ive installed davmail successfully with default configuration. I have also setup my email account with the right parameters from davmail.

    Please help.

    This is the log:
    2015-10-02 13:50:42,053 INFO [SWT] davmail - DavMail gateway stopped
    2015-10-02 13:57:04,840 DEBUG [main] davmail - OS Name: Linux Java version: 1.8.0_45 64 System tray supported Current Desktop: KDE
    2015-10-02 13:57:05,060 INFO [main] davmail - DavMail Gateway 4.6.2-2377 listening on SMTP port 1025 IMAP port 1143 CALDAV port 1080 LDAP port 1389
    2015-10-02 13:57:05,355 DEBUG [CheckRelease] davmail.DavGateway - DavMail released version: 4.6.2-2377
    2015-10-02 13:57:33,258 INFO [AWT-EventQueue-0] davmail - DavMail Gateway 4.6.2-2377 listening on SMTP port 1025 IMAP port 1143 CALDAV port 1080 LDAP port 1389
    2015-10-02 13:57:33,510 DEBUG [CheckRelease] davmail.DavGateway - DavMail released version: 4.6.2-2377
    2015-10-02 14:02:16,473 DEBUG [davmail.imap.ImapServer] davmail - Connection from /127.0.0.1 on port 1143
    2015-10-02 14:02:16,474 DEBUG [davmail.smtp.SmtpServer] davmail - Connection from /127.0.0.1 on port 1025
    2015-10-02 14:02:16,886 DEBUG [SmtpConnection-58370] davmail.exchange.ExchangeSession - Test configuration status: 302
    2015-10-02 14:02:16,886 DEBUG [ImapConnection-51000] davmail.exchange.ExchangeSession - Test configuration status: 302
    2015-10-02 14:02:16,886 DEBUG [ImapConnection-51000] davmail - > * OK [CAPABILITY IMAP4REV1 AUTH=LOGIN MOVE] IMAP4rev1 DavMail 4.6.2-2377 server ready
    2015-10-02 14:02:16,886 DEBUG [SmtpConnection-58370] davmail - > 220 DavMail 4.6.2-2377 SMTP ready at Fri Oct 02 14:02:16 CEST 2015
    2015-10-02 14:02:16,887 DEBUG [ImapConnection-51000] davmail - < 1 CAPABILITY
    2015-10-02 14:02:16,887 DEBUG [SmtpConnection-58370] davmail - < EHLO we-guess.mozilla.org
    2015-10-02 14:02:16,888 DEBUG [SmtpConnection-58370] davmail - > 250-we-guess.mozilla.org
    2015-10-02 14:02:16,888 DEBUG [SmtpConnection-58370] davmail - > 250-AUTH LOGIN PLAIN
    2015-10-02 14:02:16,888 DEBUG [SmtpConnection-58370] davmail - > 250-8BITMIME
    2015-10-02 14:02:16,889 DEBUG [SmtpConnection-58370] davmail - > 250 Hello
    2015-10-02 14:02:16,889 DEBUG [SmtpConnection-58370] davmail - < QUIT
    2015-10-02 14:02:16,889 DEBUG [SmtpConnection-58370] davmail - > 221 Closing connection
    2015-10-02 14:02:16,892 DEBUG [ImapConnection-51000] davmail - > * CAPABILITY IMAP4REV1 AUTH=LOGIN MOVE
    2015-10-02 14:02:16,892 DEBUG [ImapConnection-51000] davmail - > 1 OK CAPABILITY completed
    2015-10-02 14:02:16,893 DEBUG [ImapConnection-51000] davmail - < 2 LOGOUT
    2015-10-02 14:02:16,893 DEBUG [ImapConnection-51000] davmail - > * BYE Closing connection
    2015-10-02 14:02:16,893 DEBUG [ImapConnection-51000] davmail - > 2 OK LOGOUT completed
    2015-10-02 14:02:21,038 DEBUG [davmail.imap.ImapServer] davmail - Connection from /127.0.0.1 on port 1143
    2015-10-02 14:02:21,038 DEBUG [davmail.smtp.SmtpServer] davmail - Connection from /127.0.0.1 on port 1025
    2015-10-02 14:02:21,064 DEBUG [ImapConnection-51002] davmail.exchange.ExchangeSession - Test configuration status: 302
    2015-10-02 14:02:21,064 DEBUG [ImapConnection-51002] davmail - > * OK [CAPABILITY IMAP4REV1 AUTH=LOGIN MOVE] IMAP4rev1 DavMail 4.6.2-2377 server ready
    2015-10-02 14:02:21,064 DEBUG [SmtpConnection-58372] davmail.exchange.ExchangeSession - Test configuration status: 302
    2015-10-02 14:02:21,066 DEBUG [SmtpConnection-58372] davmail - > 220 DavMail 4.6.2-2377 SMTP ready at Fri Oct 02 14:02:21 CEST 2015
    2015-10-02 14:02:21,065 DEBUG [ImapConnection-51002] davmail - < 1 CAPABILITY
    2015-10-02 14:02:21,067 DEBUG [ImapConnection-51002] davmail - > * CAPABILITY IMAP4REV1 AUTH=LOGIN MOVE
    2015-10-02 14:02:21,067 DEBUG [ImapConnection-51002] davmail - > 1 OK CAPABILITY completed
    2015-10-02 14:02:21,068 DEBUG [SmtpConnection-58372] davmail - < EHLO we-guess.mozilla.org
    2015-10-02 14:02:21,068 DEBUG [SmtpConnection-58372] davmail - > 250-we-guess.mozilla.org
    2015-10-02 14:02:21,068 DEBUG [SmtpConnection-58372] davmail - > 250-AUTH LOGIN PLAIN
    2015-10-02 14:02:21,068 DEBUG [SmtpConnection-58372] davmail - > 250-8BITMIME
    2015-10-02 14:02:21,068 DEBUG [SmtpConnection-58372] davmail - > 250 Hello
    2015-10-02 14:02:21,068 DEBUG [SmtpConnection-58372] davmail - < QUIT
    2015-10-02 14:02:21,068 DEBUG [SmtpConnection-58372] davmail - > 221 Closing connection
    2015-10-02 14:02:21,070 DEBUG [ImapConnection-51002] davmail - < 2 LOGOUT
    2015-10-02 14:02:21,070 DEBUG [ImapConnection-51002] davmail - > * BYE Closing connection
    2015-10-02 14:02:21,070 DEBUG [ImapConnection-51002] davmail - > 2 OK LOGOUT completed
    2015-10-02 14:02:23,980 DEBUG [davmail.imap.ImapServer] davmail - Connection from /127.0.0.1 on port 1143
    2015-10-02 14:02:24,014 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Test configuration status: 302
    2015-10-02 14:02:24,015 DEBUG [ImapConnection-51004] davmail - > * OK [CAPABILITY IMAP4REV1 AUTH=LOGIN MOVE] IMAP4rev1 DavMail 4.6.2-2377 server ready
    2015-10-02 14:02:24,016 DEBUG [ImapConnection-51004] davmail - < 1 authenticate login
    2015-10-02 14:02:24,017 DEBUG [ImapConnection-51004] davmail - > + VXNlcm5hbWU6
    2015-10-02 14:02:24,017 DEBUG [ImapConnection-51004] davmail - < dm9jZW50b1xtcm9tZXJv
    2015-10-02 14:02:24,017 DEBUG [ImapConnection-51004] davmail - > + UGFzc3dvcmQ6
    2015-10-02 14:02:24,018 DEBUG [ImapConnection-51004] davmail - < **
    2015-10-02 14:02:24,110 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects(https://owa.mycompany.com/)
    2015-10-02 14:02:24,116 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects: https://owa.mycompany.com/owa/ redirectCount:1
    2015-10-02 14:02:24,125 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects: https://owa.mycompany.com/owa/auth/logon.aspx?url=https://owa.mycompany.com/owa/&reason=0 redirectCount:2
    2015-10-02 14:02:24,137 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Form based authentication detected
    2015-10-02 14:02:24,154 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Detected script based logon, redirect to form at https://owa.mycompany.com/owa/auth/logon.aspx?replaceCurrent=1&url=https%3a%2f%2fowa.mycompany.com%2fowa%2f
    2015-10-02 14:02:24,154 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects(https://owa.mycompany.com/owa/auth/logon.aspx?replaceCurrent=1&url=https%3a%2f%2fowa.mycompany.com%2fowa%2f)
    2015-10-02 14:02:24,180 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects(https://owa.mycompany.com/owa/auth.owa)
    2015-10-02 14:02:24,242 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects: https://owa.mycompany.com/owa/ redirectCount:1
    2015-10-02 14:02:25,342 WARN [ImapConnection-51004] davmail.exchange.ExchangeSession - Public folders not available: 405 Method Not Allowed at https://owa.mycompany.com/owa/
    2015-10-02 14:02:25,342 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Current user email is myname@mycompany.com, alias is my namedc6, mailPath is /exchange/myname@mycompany.com/ on Exchange2007
    2015-10-02 14:02:25,627 ERROR [ImapConnection-51004] davmail.exchange.ExchangeSession - 405 Method Not Allowed at https://owa.mycompany.com/owa/myname@mycompany.com/
    2015-10-02 14:02:25,628 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Unable to get mail folder at /exchange/myname@mycompany.com/, Webdav not available on Exchange server, retry with EWS
    2015-10-02 14:02:25,703 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects(https://owa.mycompany.com/)
    2015-10-02 14:02:25,714 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects: https://owa.mycompany.com/owa/ redirectCount:1
    2015-10-02 14:02:25,727 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects: https://owa.mycompany.com/owa/auth/logon.aspx?url=https://owa.mycompany.com/owa/&reason=0 redirectCount:2
    2015-10-02 14:02:25,737 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Form based authentication detected
    2015-10-02 14:02:25,739 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Detected script based logon, redirect to form at https://owa.mycompany.com/owa/auth/logon.aspx?replaceCurrent=1&url=https%3a%2f%2fowa.mycompany.com%2fowa%2f
    2015-10-02 14:02:25,739 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects(https://owa.mycompany.com/owa/auth/logon.aspx?replaceCurrent=1&url=https%3a%2f%2fowa.mycompany.com%2fowa%2f)
    2015-10-02 14:02:25,763 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects(https://owa.mycompany.com/owa/auth.owa)
    2015-10-02 14:02:25,804 DEBUG [ImapConnection-51004] davmail - executeFollowRedirects: https://owa.mycompany.com/owa/ redirectCount:1
    2015-10-02 14:02:27,477 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Current user email is myname@mycompany.com, alias is my namedc6 on Exchange2010_SP1
    2015-10-02 14:02:27,477 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Session davmail.exchange.ews.EwsExchangeSession@548183fb created
    2015-10-02 14:02:27,477 DEBUG [ImapConnection-51004] davmail.exchange.ExchangeSession - Created new session davmail.exchange.ews.EwsExchangeSession@548183fb for user mycompany\myname
    2015-10-02 14:02:27,478 DEBUG [ImapConnection-51004] davmail - > 1 OK Authenticated
    2015-10-02 14:02:27,524 DEBUG [ImapConnection-51004] davmail - < 2 logout
    2015-10-02 14:02:27,525 DEBUG [ImapConnection-51004] davmail - > * BYE Closing connection
    2015-10-02 14:02:27,525 DEBUG [ImapConnection-51004] davmail - > 2 OK LOGOUT completed
    2015-10-02 14:02:27,525 WARN [ImapConnection-51004] davmail.imap.ImapConnection - Client closed connection
    2015-10-02 14:02:27,526 WARN [ImapConnection-51004] davmail - Exception closing client output stream Socket closed
    java.net.SocketException: Socket closed
    at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:116)
    at java.net.SocketOutputStream.write(SocketOutputStream.java:153)
    at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
    at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
    at java.io.FilterOutputStream.close(FilterOutputStream.java:158)
    at davmail.AbstractConnection.close(AbstractConnection.java:258)
    at davmail.imap.ImapConnection.run(ImapConnection.java:663)

     

    Last edit: xtrmxtrm 2015-10-02
  • Mickael Guessant

    This message is just a warning: connection is successfull, but client closes connection as soon as it receives * BYE => DavMail is unable to send final OK LOGOUT message.

    Mailbox access should work fine.

     
  • xtrmxtrm

    xtrmxtrm - 2015-10-05

    Thank you Mickael,

    Yes as you said everything should be ok since it also says the account and password is right and it can connect to the owa server.
    However when I receive the popUp warning of socket closed, the email account is never added in Thunderbird and I cannot access it.

    Do you know any way to be able to add the account to Thunderbird in these cases of exceptions? I have read its sometimes a known issue in Thunderbird.

    Thanks.

     
  • xtrmxtrm

    xtrmxtrm - 2015-10-11

    However I couldnt solve the socket error exception while Thunderbird was trying to create the account, I could bypass it using other computer and importing the thunderbird account created in the other computer to my current computer.
    Thunderbird has a personal folder with all your settings and extensions, and some of them could be the cause of errors in davmail. Renaming that thunderbird folder and starting from a clean account could be another solution.

     
  • Mickael Guessant

    Ok, then this is probably a Thunderbird issue

     

Log in to post a comment.