You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by Owen Gu <ow...@topcmm.com> on 2008/05/28 16:32:49 UTC

chat server often deaded with mina 2.0-m1

Hi,
Our chat server is deveolped with mina-2.0 m1 version, we got a very
emergent problem, the chat server dead every week.
The attachment contains thread dump that was generated when we made the
server dead by some testing tools, I think the dead lock or out of memory
problem caused the server down.
Please help me to solove this problem, it's very emergent, thank you.

Re: chat server often deaded with mina 2.0-m1

Posted by Owen Gu <ow...@topcmm.com>.
Hi,
I'll provide more clues.
1. My server vm arguments: -server -Xms128m -Xmx512m -Xss128k
-XX:+AggressiveOpts -XX:+UseParallelGC -XX:+UseBiasedLocking -XX:NewSize=64m
-XX:+HeapDumpOnOutOfMemoryError
2. I'm using the WriteThrottleFilter to prevent the OutOfMemory problem and
I got some informations after server deadClass: class
org.apache.mina.filter.traffic.WriteFloodException<http://img.shanliao.com:7000/class/0x4573d880>
Instance
data members: backtrace (L) : [Ljava.lang.Object;@0x538e7460 (20
bytes)<http://img.shanliao.com:7000/object/0x538e7460>
cause (L) : org.apache.mina.filter.traffic.WriteFloodException@0x538e7440
(28 bytes) <http://img.shanliao.com:7000/object/0x538e7440>
detailMessage (L) : Write requests flooded - session: 178 / 512 msgs, 42000
/ 131072 bytes, service: 131072 / 131072 msgs, 37029706 / 67108864 bytes,
global: 131072 / 262144 msgs, 37029706 / 131657728 bytes. (24
bytes)<http://img.shanliao.com:7000/object/0x538e7650>
requests (L) : java.util.Collections$UnmodifiableRandomAccessList@0x538e77f0
(16 bytes) <http://img.shanliao.com:7000/object/0x538e77f0>
stackTrace (L) : <null>
References to this object:
org.apache.mina.filter.traffic.WriteFloodException@0x538e7440
(28 bytes) <http://img.shanliao.com:7000/object/0x538e7440> : field cause
org.apache.mina.common.DefaultWriteFuture@0x538e7840 (33
bytes)<http://img.shanliao.com:7000/object/0x538e7840>: field result
org.apache.mina.common.IoFilterEvent@0x538e7428 (24
bytes)<http://img.shanliao.com:7000/object/0x538e7428>: field
parameter

On Wed, May 28, 2008 at 11:43 PM, Mark Webb <el...@gmail.com> wrote:

> I had noticed some deadlock conditions as well, but after you
> mentioned you ran into an out of memory error I got confused.  I will
> take a look at this again when I get a free minute.
>
> On Wed, May 28, 2008 at 11:23 AM, Owen Gu <ow...@topcmm.com> wrote:
> > Please check the thread dump, it seems the "NioProcessor-2" thread was
> > blocked and lock the object 0x49958e38, and the other NioProcessor were
> > waiting for the object 0x49958e38, I think this caused deadlock. But
> after I
> > used jstack dump the thread one minutes, I saw the system alert out of
> > memory, So I'm not sure what caused my server dead, please help me
> analyse
> > the thread dump, thanks.
> >
> > On Wed, May 28, 2008 at 10:58 PM, Mark Webb <el...@gmail.com>
> wrote:
> >
> >> is the system deadlocking or running out of memory?
> >>
> >>
> >> On Wed, May 28, 2008 at 10:32 AM, Owen Gu <ow...@topcmm.com> wrote:
> >> > Hi,
> >> > Our chat server is deveolped with mina-2.0 m1 version, we got a very
> >> > emergent problem, the chat server dead every week.
> >> > The attachment contains thread dump that was generated when we made
> the
> >> > server dead by some testing tools, I think the dead lock or out of
> memory
> >> > problem caused the server down.
> >> > Please help me to solove this problem, it's very emergent, thank you.
> >> >
> >> >
> >> >
> >>
> >
>

Re: chat server often deaded with mina 2.0-m1

Posted by Mark Webb <el...@gmail.com>.
I had noticed some deadlock conditions as well, but after you
mentioned you ran into an out of memory error I got confused.  I will
take a look at this again when I get a free minute.

On Wed, May 28, 2008 at 11:23 AM, Owen Gu <ow...@topcmm.com> wrote:
> Please check the thread dump, it seems the "NioProcessor-2" thread was
> blocked and lock the object 0x49958e38, and the other NioProcessor were
> waiting for the object 0x49958e38, I think this caused deadlock. But after I
> used jstack dump the thread one minutes, I saw the system alert out of
> memory, So I'm not sure what caused my server dead, please help me analyse
> the thread dump, thanks.
>
> On Wed, May 28, 2008 at 10:58 PM, Mark Webb <el...@gmail.com> wrote:
>
>> is the system deadlocking or running out of memory?
>>
>>
>> On Wed, May 28, 2008 at 10:32 AM, Owen Gu <ow...@topcmm.com> wrote:
>> > Hi,
>> > Our chat server is deveolped with mina-2.0 m1 version, we got a very
>> > emergent problem, the chat server dead every week.
>> > The attachment contains thread dump that was generated when we made the
>> > server dead by some testing tools, I think the dead lock or out of memory
>> > problem caused the server down.
>> > Please help me to solove this problem, it's very emergent, thank you.
>> >
>> >
>> >
>>
>

Re: chat server often deaded with mina 2.0-m1

Posted by Owen Gu <ow...@topcmm.com>.
Please check the thread dump, it seems the "NioProcessor-2" thread was
blocked and lock the object 0x49958e38, and the other NioProcessor were
waiting for the object 0x49958e38, I think this caused deadlock. But after I
used jstack dump the thread one minutes, I saw the system alert out of
memory, So I'm not sure what caused my server dead, please help me analyse
the thread dump, thanks.

On Wed, May 28, 2008 at 10:58 PM, Mark Webb <el...@gmail.com> wrote:

> is the system deadlocking or running out of memory?
>
>
> On Wed, May 28, 2008 at 10:32 AM, Owen Gu <ow...@topcmm.com> wrote:
> > Hi,
> > Our chat server is deveolped with mina-2.0 m1 version, we got a very
> > emergent problem, the chat server dead every week.
> > The attachment contains thread dump that was generated when we made the
> > server dead by some testing tools, I think the dead lock or out of memory
> > problem caused the server down.
> > Please help me to solove this problem, it's very emergent, thank you.
> >
> >
> >
>

Re: chat server often deaded with mina 2.0-m1

Posted by Mark Webb <el...@gmail.com>.
is the system deadlocking or running out of memory?


On Wed, May 28, 2008 at 10:32 AM, Owen Gu <ow...@topcmm.com> wrote:
> Hi,
> Our chat server is deveolped with mina-2.0 m1 version, we got a very
> emergent problem, the chat server dead every week.
> The attachment contains thread dump that was generated when we made the
> server dead by some testing tools, I think the dead lock or out of memory
> problem caused the server down.
> Please help me to solove this problem, it's very emergent, thank you.
>
>
>