You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-user@james.apache.org by Theodore Watson <tp...@drexel.edu> on 2005/05/07 01:31:05 UTC

entire inboxes deleted...OutOfMemoryError

Several of our clients are using a piece of software with pop3-client
capability called GoldMine. It leaves emails on the James server rather
then moving them off.

I couple days ago, each user employing GoldMine as a client tragicly lost
their entire inboxes. I noticed in the "mailstore" log a series of these
errors were logged during that time...

04/05/05 11:08:30 DEBUG mailstore: Exception retrieving mail:
java.lang.RuntimeException: Exception caught while retrieving an
object, cause: java.lang.OutOfMemoryError, so we're deleting it... good
riddance!

At least one user had 400+ emails on the server.

Am I to infer from this that James deleted these messages because it was
out of memory?  When was it out of memory?  I am assuming it was at the
time these users were retrieving there email.

Thanks.

Ted

---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: entire inboxes deleted...OutOfMemoryError

Posted by Theodore Watson <tp...@drexel.edu>.
> I couple days ago, each user employing GoldMine as a client tragicly lost
> their entire inboxes. I noticed in the "mailstore" log a series of these
> errors were logged during that time...
>
> 04/05/05 11:08:30 DEBUG mailstore: Exception retrieving mail:
> java.lang.RuntimeException: Exception caught while retrieving an
> object, cause: java.lang.OutOfMemoryError, so we're deleting it... good
> riddance!

There were actually serveral hundred of these messages, which was
consistent with the number of emails being retrieved.


On Fri, 6 May 2005, Theodore Watson wrote:

> Several of our clients are using a piece of software with pop3-client
> capability called GoldMine. It leaves emails on the James server rather
> then moving them off.
>
> I couple days ago, each user employing GoldMine as a client tragicly lost
> their entire inboxes. I noticed in the "mailstore" log a series of these
> errors were logged during that time...
>
> 04/05/05 11:08:30 DEBUG mailstore: Exception retrieving mail:
> java.lang.RuntimeException: Exception caught while retrieving an
> object, cause: java.lang.OutOfMemoryError, so we're deleting it... good
> riddance!
>
> At least one user had 400+ emails on the server.
>
> Am I to infer from this that James deleted these messages because it was
> out of memory?  When was it out of memory?  I am assuming it was at the
> time these users were retrieving there email.
>
> Thanks.
>
> Ted
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
> For additional commands, e-mail: server-user-help@james.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: entire inboxes deleted...OutOfMemoryError

Posted by Serge Knystautas <se...@lokitech.com>.
Theodore Watson wrote:
> Just so I have something to relay to others in my company... Is it fair to
> assume that files were deleted from James' filesystem as a result of some
> exception handling?

Yes Ted, long story to follows... (at least this is how it worked once, 
and I'm guessing is what happened)

James stores messages in the file system uses two files (one is the mime 
message, the other is delivery information).  There were situations 
where James would tell the computer to delete both files, but because of 
some file stream not closing or something wrong, the file system would 
only delete one of them.  This left James with 1 out of a pair of files, 
something usable, and something we wanted to delete in the first place.

As a result, code was added so that if there is an exception trying to 
load a message, have James delete the message.  This seemed ok since 
other conceived scenarios (corrupt file, 0-byte file, something 
unusable) were assumed to be permanent situations.

Obviously OutOfMemory does not mean there is anything wrong with the 
file, so we definitely want to avoid this behavior.  Also as Noel said, 
losing data is really pretty bad, so we should be more specific on what 
exceptions trigger this delete behavior.

-- 
Serge Knystautas
Lokitech >> software . strategy . design >> http://www.lokitech.com
p. 301.656.5501
e. sergek@lokitech.com

---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


RE: entire inboxes deleted...OutOfMemoryError

Posted by "Noel J. Bergman" <no...@devtech.com>.
Theodore Watson wrote:

> Just so I have something to relay to others in my company... Is it fair
> to assume that files were deleted from James' filesystem as a result of
> some exception handling?

Yes.  Definitely seems a bug.  Not one that I recall seeing reported before,
even though the code has been that way for ages.  Data loss is a very high
priority to fix.  I don't believe that any of us consider data loss
acceptable, and this is the first report of it that I recall seeing in a
very long time.

	--- Noel


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


RE: entire inboxes deleted...OutOfMemoryError

Posted by Theodore Watson <tp...@drexel.edu>.
Ok, thanks for your attention.

Just so I have something to relay to others in my company... Is it fair to
assume that files were deleted from James' filesystem as a result of some
exception handling?

On Sat, 7 May 2005, Noel J. Bergman wrote:

> As best I can tell, File_Persistent_Object_Repository that ran out of memory
> on the get() call.  That got caught in AvalonMailRepository.retrieve(),
> which has that message in it.  Something else probably chewed up the memory,
> and it was detected here.
>
> We will try to get a fix for that in place ASAP, but you might wnat to
> change to using dbfile or db instead of file for the message store if you
> can, or allocate more memory for the JVM.
>
> If you don't mind, would you please post this in a JIRA issue?  And remind
> us to change that error message while we're at it.
>
> 	--- Noel
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
> For additional commands, e-mail: server-user-help@james.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


RE: entire inboxes deleted...OutOfMemoryError

Posted by "Noel J. Bergman" <no...@devtech.com>.
As best I can tell, File_Persistent_Object_Repository that ran out of memory
on the get() call.  That got caught in AvalonMailRepository.retrieve(),
which has that message in it.  Something else probably chewed up the memory,
and it was detected here.

We will try to get a fix for that in place ASAP, but you might wnat to
change to using dbfile or db instead of file for the message store if you
can, or allocate more memory for the JVM.

If you don't mind, would you please post this in a JIRA issue?  And remind
us to change that error message while we're at it.

	--- Noel


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


RE: entire inboxes deleted...OutOfMemoryError

Posted by Theodore Watson <tp...@drexel.edu>.
> Theodore Watson @ Drexel wrote:
>
> > a client tragicly lost their entire inboxes.
>
> > mailstore: Exception retrieving mail: java.lang.RuntimeException:
> >            Exception caught while retrieving an object, cause:
> >            java.lang.OutOfMemoryError
> >            so we're deleting it... good riddance!
>
> Can you be specific about which version of JAMES and what kind of mailstore?
> JAMES should not lose messages.
>

I am using 2.2.0.

Just by reading the provided logs, I don't know what to assume James'
handled an OutOfMemoryError by deleting something.  There were a lot
of emails missing at the same time I received these errors.  Four inboxes
were cleared at this time.  All other logs show normal activity.  Would it
be any help to see the others?

---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


RE: entire inboxes deleted...OutOfMemoryError

Posted by "Noel J. Bergman" <no...@devtech.com>.
Theodore Watson @ Drexel wrote:

> a client tragicly lost their entire inboxes.

> mailstore: Exception retrieving mail: java.lang.RuntimeException:
>            Exception caught while retrieving an object, cause:
>            java.lang.OutOfMemoryError
>            so we're deleting it... good riddance!

Can you be specific about which version of JAMES and what kind of mailstore?
JAMES should not lose messages.

	--- Noel


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org