Connection dropped by IMAP server

Hello Everyone, I need some help!

We have an Xserve G5 running 10.4.2 Server as our mail server. On-campus, people use Entourage to get their mail; off-campus they use Squirrelmail.

Here's the problem: Now and then a user will not be able to use Entourage to connect to their email account. Squirrelmail also doesn't work and when they try to login in SM, they get the following error: "ERROR: Connection dropped by IMAP server."

I used 'ps -ax' to view all processes on the mail server. There are a bunch (like 30) lines that say 'imapd: localhost [::1]' with no username afterwards. Also, in Server Admin's Mail Service window, there are a bunch of lines (about 30) in the Connections pane that have no username and the address is localhost. My guess is these are Squirrelmail sessions that didn't completely close because the user didn't click Sign Out or something. Just a guess. I don't know. I also don't know if this is related to my problem, or another issue going on at the same time.

Anyway. So, let's say johndoe gets the "dropped by IMAP server" error. There is a line in 'ps -ax' that says 'imapd: localhost [::1] johndoe user.johndoe' and for the life of me, I can't kill the process. I can kill everything else.

So I stopped the Mail Service via Server Admin and refreshed the Connections pane. Everyone disappears except johndoe. 'ps -ax' shows all other connections are gone except johndoe. Start Mail Service, johndoe still gets "dropped by IMAP server" error when trying to login.

So I tried to restart the server via Apple menu, Restart. Server hangs after dock and desktop items disappear. Just shows background...endlessly. Have to hold down Xserve power button for 5 seconds. Wait a few seconds, turn it back on, everything boots up fine. johndoe can now log in.

Seems trivial, eh? Well, I've had this happen to two other users in the last 2 months. If the pattern holds, johndoe's account is likely to do this again a few times in the next week. I'll have no idea why and no way to fix it except restart the entire server. And I think that's awful that I can't resolve this issue without cutting off ALL email access to resolve one account. But anyway. Plus, johndoe will not receive any email while this is happening. Messages to him get put in La La Land. I can't find them to deliver into his mailbox once he can log in again. Grrrr. I'm guessing they're just lost forever.

Does anyone have any ideas? Have you seen that SquirrelMail error before? Does anyone know which log files I should start monitoring to maybe find more answers??? (Please be specific: for example, tell me the full location.)

Thanks for your help!

Posted on Sep 15, 2005 5:06 PM

Reply
37 replies

Sep 16, 2005 1:25 PM in response to Patrick Young2

I'm only using IPv4 but I see that an IPv6 address is assigned.


Me too... and that's the reason why I always disable ipv6 on all interfaces. (System preferences - Network - interface - TCP/IP - Configure IPv6 button).
If I don't need it, I don't want it.

Out of curiosity, how would IP addressing cause this?


Who knows? It is a wild guess, after all 🙂
But since I never saw your problem before, it may be worth a try...

Sep 17, 2005 4:31 PM in response to Patrick Young2

I've been having the EXACT same issue this past week as well - I restarted the server from home today, and it seems to be hung up (can't SSH into it), so there's nothing I can do until I can physically get to the server (probably not till Monday).

PLUS, for the last couple of nights, after backing up the server remotely via Retrospect over my network Mail service has stopped and not come back up - I am using Alex's mailbfr scripts nightly and they run before Retrospect gets to the server - but in the morning after the backups, I've checked the services running via Server Admin and Mail is not up again. I looked at my Retrospect logs, and for a couple of nights now, Retrosp hasn't been able to reach my server - I think this may be a different issue altogether, but I'm curious to know if they're related.

Let us know if you figure anything out - I will also post logs when I get the server back up and running (tomorrow or Monday)

Sep 19, 2005 8:53 AM in response to Blair Carswell

Some Log info --
mail.log:
Sep 17 13:58:02 Mail postfix/qmgr[10653]: 1AC20DEC39: removed
Sep 17 13:58:45 Mail postfix/smtpd[10680]: connect from tx02.mailwise.com[216.75.199.17]
Sep 17 13:58:45 Mail postfix/smtpd[10699]: connect from tx02.mailwise.com[216.75.199.17]
Sep 17 13:58:45 Mail postfix/smtpd[10700]: connect from tx02.mailwise.com[216.75.199.17]
Sep 17 13:58:45 Mail postfix/smtpd[10680]: 8319EDEC4F: client=tx02.mailwise.com[216.75.199.17]
Sep 17 13:58:45 Mail postfix/smtpd[10701]: connect from tx02.mailwise.com[216.75.199.17]
Sep 17 13:58:45 Mail postfix/smtpd[10699]: 8BCD6DEC50: client=tx02.mailwise.com[216.75.199.17]
Sep 17 13:58:45 Mail postfix/cleanup[10668]: 8319EDEC4F: message-id=<OF68374A50.267A165F-ON8825707F.001AFD9F-8825707F.001AFDA0@notes.gap .com>
Sep 17 13:58:45 Mail postfix/smtpd[10700]: 9B7B0DEC51: client=tx02.mailwise.com[216.75.199.17]
Sep 17 13:58:Sep 19 08:37:07 Mail postfix/master[64]: daemon started -- version 2.1.5 **(SERVER RESET AT THIS TIME, hung up till MONDAY morning)
Sep 19 08:37:08 Mail postfix/qmgr[163]: 10C9CA8A04: from=<sroth@churchillschool.com>, size=1211, nrcpt=1 (queue active)
Sep 19 08:37:50 Mail postfix/smtp[178]: connect to lacnyc.com[66.118.136.67]: Operation timed out (port 25)
Sep 19 08:37:50 Mail postfix/smtp[178]: 10C9CA8A04: to=<tonyp@lacnyc.com>, relay=none, delay=515530, status=deferred (connect to lacnyc.com[66.118.136.67]: Operation timed out)
Sep 19 08:37:50 Mail postfix/qmgr[163]: 10C9CA8A04: from=<sroth@churchillschool.com>, status=expired, returned to sender
Sep 19 08:37:50 Mail postfix/cleanup[316]: 4D489DF038: message-id=<20050919123750.4D489DF038@churchillschool.com>
Sep 19 08:37:50 Mail postfix/qmgr[163]: 4D489DF038: from=, size=2958, nrcpt=1 (queue active)
Sep 19 08:37:50 Mail postfix/qmgr[163]: 10C9CA8A04: removed
Sep 19 08:37:54 Mail postfix/pipe[330]: 4D489DF038: to=<xxxxx@churchillschool.com>, relay=cyrus, delay=4, status=sent (churchillschool.com)

mailaccess.log:
(this is mailaccess.log.0.gz)
Sep 16 16:23:20 Mail imap[2789]: idle for too long, closing connection
Sep 16 16:24:12 Mail imap[5633]: idle for too long, closing connection
Sep 16 16:24:12 Mail imap[5644]: idle for too long, closing connection
Sep 16 16:40:27 Mail imap[5627]: idle for too long, closing connection
Sep 16 17:29:51 Mail imap[7220]: idle for too long, closing connection
Sep 16 17:42:43 Mail imap[7247]: idle for too long, closing connection
Sep 16 19:22:58 Mail imap[7250]: idle for too long, closing connection
Sep 16 19:22:58 Mail imap[7251]: idle for too long, closing connection
Sep 16 19:27:58 Mail imap[7706]: idle for too long, closing connection
Sep 16 19:27:58 Mail imap[7707]: idle for too long, closing connection
Sep 16 20:27:58 Mail imap[7715]: idle for too long, closing connection
Sep 16 20:27:58 Mail imap[7716]: idle for too long, closing connection
(mail stopped being accessible sometime on Friday Night, roughly at this time in the logs)
MACHINE WAS RESET on SATURDAY at around 2 or 2:30pm, BUT HUNG until it was manually reset on Monday morning around 8:30am
User logged in
Sep 19 08:37:31 Mail imap[296]: login: [10.3.8.215] mxxxxxxxxx plaintext User logged in
Sep 19 08:37:31 Mail imap[296]: skiplist: recovered /var/imap/user/m/mxxxxxx.seen (4 records, 15052 bytes) in 0 seconds
Sep 19 08:37:32 Mail imap[299]: login: [10.3.9.14] exxxxx plaintext User logged in
Sep 19 08:37:32 Mail imap[300]: login: [10.3.6.18] mxxxxxx plaintext User logged in
Sep 19 08:37:32 Mail imap[300]: skiplist: recovered /var/imap/user/m/mxxxxx.seen (4 records, 10652 bytes) in 0 seconds
Sep 19 08:37:33 Mail imap[301]: login: [10.3.6.18] mxxxxx plaintext User logged in
Sep 19 08:37:34 Mail imap[302]: login: [10.3.6.18] mxxxxx plaintext User logged in
Sep 19 08:37:38 Mail imap[303]: login: [10.3.5.26] bxxxxx plaintext User logged in
Sep 19 08:37:39 Mail imap[303]: skiplist: recovered /var/imap/user/b/bxxxxx.seen (3 records, 9852 bytes) in 0 seconds

To f

Sep 19, 2005 11:24 AM in response to Blair Carswell

Also, this should have been at the end of this post (may have been too long):

To further compound things, my Retrospect logs are telling me the Mail server hasn't been backed up since the 14th, and since then it has been reporting an error along the lines of "network communication failed" - I'm not sure where this fits in the puzzle, but its troubling.

Oh, plus the fact that the A/C in my server room seems to have shut down for about 24 hours over the weekend, as I have a handful of overheating errors in my logs.

Thanks

Sep 20, 2005 4:20 PM in response to Patrick Young2

I dug through my log files and couldn't find anything useful that pertained to my problem. So I bumped up the level of logging to debug. Surely, somethiing ought to be logged when this happens again.

Sorry I don't have much more information to give you guys. Keep checking in, this is bound to happen again. I think Blair has other unrelated issues involved, but maybe an expert will spot something that is related to this topic in his posted log files.

Please let us all know if you come up with a solution to prevent "Connection dropped by IMAP server" on 10.4.2 server. Thank you!

Sep 23, 2005 7:31 AM in response to Patrick Young2

Patrick, I did the same thing with my logs and found that the reason my users couldn't connect was that my maximum number of users was being reached - for some reason, all of my users have AT LEAST TWO connections per username and IP address - I'm still not sure if this is 'normal' - anyway, sometimes my users had as many as 5-10 connections per user... I think for some reason my server wasn't automatically dropping my users with the usual "idle for too long, disconnecting user" message.

For some reason, once my maximum users had been reached it seemed like even if people were quitting mail or squirrelmail, the server was still keeping the connection active.

Anyway, I decided to try doubling the maximum number of connected users, restarting the machine, and since then the server hasn't stopped working.

Sep 23, 2005 3:19 PM in response to Blair Carswell

I had the same problem. at first: maximum of 100 connections only had ~50 users. then, for an unknown reason, the connections topped out. had to pull the plug on the server (yikes). set the maximum to 1000 connections, and thought everything was fine. then, on monday, found out that my server had 1000+ connections (all IMAP). again, i had to unplug it to get anywhere. mac support couldn't seem to duplicate the error - yes each user should only have one connection as long as they are only logged on from one machine - and suggested doing a repair on the mail database. that didn't work, and apple said they didn't have any other ideas. now my server is ok, but users still have multiple connections.

alex, are there any time-out settings either on the server or clients for mail.app?

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Connection dropped by IMAP server

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.