Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

STORE command returning unexpected status using Exchange #11

Closed
buchs-kevin opened this issue Jul 16, 2015 · 3 comments
Closed

STORE command returning unexpected status using Exchange #11

buchs-kevin opened this issue Jul 16, 2015 · 3 comments
Labels

Comments

@buchs-kevin
Copy link

I'm trying to get store of \Deleted flag working with Microsoft Exchange. I've adopted the code from demo1, I get back logging like this:

--- STORE ---
imap: unexpected completion status ("PQZGK7 NO Command received in Invalid state.")

Logout reason: Microsoft Exchange Server 2010 IMAP4 server signing off.
Close reason: end of stream
Connection closing (flush=false)

I've tried browsing the source code and I'm not getting very far with that.

@mxk
Copy link
Owner

mxk commented Jul 17, 2015

The server is telling you that the STORE command cannot be executed in the current connection state. I can't tell you why that is. Maybe one of the preceding commands failed or maybe the mailbox isn't selected with read-write access. Enable raw logging, as in the demo, to see exactly what is being sent and received.

@mxk mxk added the question label Jul 17, 2015
@buchs-kevin
Copy link
Author

Maxim,

Thanks for the reply. You were exactly right to suggest I didn’t have the mailbox open with read-write access. Such a stupid mistake.

I do have a different problem and if you are willing to take a quick look, I would appreciate it. I have gotten intermittent connection errors, coming on the imap.DialTLS call. I've been trying to get our MS Exchange support team to look up the logs to see what is going on. Here is the transaction/message (I didn't have the raw logging turned on in this case and cannot regenerate the error now):

Connected to 10.128.208.35:993 (Tag=FDMIL)
S: (WSARecv tcp 172.24.108.71:5386: An existing connection was forcibly closed by the remote host.)
Close reason: protocol error
Connection closing (flush=false)
Greeting error: WSARecv tcp 172.24.108.71:5386: An existing connection was forcibly closed by the remote host.
panic: WSARecv tcp 172.24.108.71:5386: An existing connection was forcibly closed by the remote host.

Thanks.

Kevin Buchs Cloud Planning Services Phone: 507-538-5459
Mayo Clinic 200 1st. St SW Rochester, MN 55905 http://mayoclinic.org

From: Maxim Khitrov [mailto:notifications@github.com]
Sent: Thursday, July 16, 2015 8:10 PM
To: mxk/go-imap
Cc: Buchs, Kevin J., M.S.
Subject: Re: [go-imap] STORE command returning unexpected status using Exchange (#11)

The server is telling you that the STORE command cannot be executed in the current connection state. I can't tell you why that is. Maybe one of the preceding commands failed or maybe the mailbox isn't selected with read-write access. Enable raw logging, as in the demo, to see exactly what is being sent and received.


Reply to this email directly or view it on GitHubhttps://github.com//issues/11#issuecomment-122141753.

@mxk
Copy link
Owner

mxk commented Jul 17, 2015

Hard to say without raw logging. If it's intermittent, perhaps your server has connection rate limit enabled: https://technet.microsoft.com/en-us/library/bb123712%28v=exchg.150%29.aspx

@mxk mxk closed this as completed Mar 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants