You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by James Sherwood <js...@romulin.com> on 2004/06/01 13:05:50 UTC

Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass

Ran out of memory last night again

Set to 512m and ran out at 284m
Maybe I am missing a paramater in the tomcat setup on windows or something

Frustrating

James

----- Original Message ----- 
From: "Mark Lowe" <ma...@boxstuff.com>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Monday, May 31, 2004 4:04 PM
Subject: Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass


> 300 mb sounds a lot, i've got a hibernate and struts flavored app
> running with a 128 limit, and thats being generous.
>
> I haven't measured anything but top looks happy, with 5.0.25 with jk to
> apache 2.0.47. Had a bit of traffic this afternoon albeit nothing
> heavy, had 5 simultaneously this afternoon. But nothing huge.
>
> Mark
>
> On 31 May 2004, at 17:54, James Sherwood wrote:
>
> > Thanks Mark,
> >
> > I have it currently running bypassing the mod_jk with rewrite to port
> > 8080.
> >
> > The memory has ramped to 327 mb so far which is not anything to worry
> > about.
> >
> > I had this problem on our linux box but I had forgotten the -server
> > option
> > and that took care of it.
> > The problem is, windows doesnt accept -server.
> >
> > Ill continue to monitor it with the mod_jk bypass in.
> >
> >
> > James
> >
> >
> > ----- Original Message -----
> > From: "Mark Lowe" <ma...@boxstuff.com>
> > To: "Tomcat Users List" <to...@jakarta.apache.org>
> > Sent: Monday, May 31, 2004 12:19 PM
> > Subject: Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass
> >
> >
> >> I've just set 5.0.25 up and it will run with mod_jk/1.2.3-dev and
> >> Apache/2.0.47 , I'll see if i get the same thing happening.
> >>
> >> When i was having problems i was getting a decoding error written to
> >> catalina log, which 5.0.24+ hasn't given me. 5.0.24 has been working
> >> quite happily but the next man mentioned a session error so I took his
> >> word for it and upgraded.
> >>
> >> You could have tomcat being served from an ip alias, but will depend
> >> on
> >> you configuration. And might take longer than getting jk sorted.
> >>
> >> For the moment I can just say i'll keep and eye on things and see if
> >> the same happens to me.
> >>
> >> Mark
> >>
> >> On 31 May 2004, at 14:23, James Sherwood wrote:
> >>
> >>> There are no errors anywhere that I can find in any logs.  The memory
> >>> just
> >>> slowly ramps up till an out of memory error happens.
> >>>
> >>> James
> >>>
> >>> ----- Original Message -----
> >>> From: "Mark Lowe" <ma...@boxstuff.com>
> >>> To: "Tomcat Users List" <to...@jakarta.apache.org>
> >>> Sent: Monday, May 31, 2004 9:04 AM
> >>> Subject: Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass
> >>>
> >>>
> >>>> What does your catalina log have to say for itself?
> >>>>
> >>>>
> >>>>
> >>>>
> >>>> On 31 May 2004, at 13:59, James Sherwood wrote:
> >>>>
> >>>>> As I posted before, I get a memory leak using mod_jk 1.2 with
> >>>>> Tomcat
> >>>>> 5.0.25
> >>>>> and Apache 2.049
> >>>>>
> >>>>> I beleive it may be related to the mod_jk connector and since I am
> >>>>> not
> >>>>> actually serving up anything with apache yet I want to just bypass
> >>>>> the
> >>>>> connector for 1 site and hit tomcat directly. I have to use apache
> >>>>> for
> >>>>> other
> >>>>> things on the server so I cannot just use tomcat.
> >>>>>
> >>>>> Any idea the best route for this? (of course a fix for the leak is
> >>>>> the
> >>>>> best
> >>>>> route:)
> >>>>> My route works but certian urls within the site do not
> >>>>> work(although
> >>>>> I
> >>>>> think
> >>>>> I could get them working).
> >>>>>
> >>>>> The way I have done it is this:
> >>>>>
> >>>>> <VirtualHost *>
> >>>>>
> >>>>> ServerName mysite.ca
> >>>>>
> >>>>> RewriteEngine on
> >>>>>
> >>>>> RewriteCond %{HTTP_HOST} ^www\.mysite\.ca$ [NC]
> >>>>>
> >>>>> RewriteRule ^(.*) http://localhost:8080$1 [p]
> >>>>>
> >>>>> </VirtualHost>
> >>>>>
> >>>>>
> >>>>>
> >>>>> Thanks, James
> >>>>>
> >>>>>
> >>>>>
> >>>>> ------------------------------------------------------------------- 
> >>>>> --
> >>>>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >>>>> For additional commands, e-mail:
> >>>>> tomcat-user-help@jakarta.apache.org
> >>>>>
> >>>>
> >>>>
> >>>> -------------------------------------------------------------------- 
> >>>> -
> >>>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >>>> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >>>>
> >>>>
> >>>
> >>>
> >>>
> >>> ---------------------------------------------------------------------
> >>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >>> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >>>
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> >> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >>
> >>
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>



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


Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass

Posted by David Rees <dr...@greenhydrant.com>.
Michiel Toneman wrote, On 6/2/2004 2:18 AM:
>
> I can confirm that this works with mod_jk too.
> 
> I'm a little surprised that fixing this rather horrible memory leak 
> doesn't appear to be a high priority.  We were almost at a point of 
> abandoning Tomcat altogether since we couldn't keep our test environment 
> running for more than 2 days without OutOfMemory problems while it would 
> run for weeks on end with JRun3. Adding this line made all our problems 
> go away, and we are now well on our way to completing our migration to 
> Tomcat.

This particular issue has been fixed in Tomcat 5.0.x already.  Please 
download the latest release.

As the thread starter James mentioned, his memory leak problem was not 
because of this issue as he is running the latest, 5.0.25.

-Dave

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


Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass

Posted by Michiel Toneman <Mi...@bibit.com>.
Adrian Barnett wrote:

>
>>> Ran out of memory last night again
>>>
>>> Set to 512m and ran out at 284m
>>> Maybe I am missing a paramater in the tomcat setup on windows or  
>>> something
>>>
>>> Frustrating
>>>
>>> James
>>
>
> I was having a memory leak using mod_jk2, and it was fixed by adding
> request.registerRequests=false
> to tomcat/conf/jk2.properties.
> I don't know if this would work with mod_jk, but it might be worth a try.
>
> Adrian
>
>
I can confirm that this works with mod_jk too.

I'm a little surprised that fixing this rather horrible memory leak 
doesn't appear to be a high priority.  We were almost at a point of 
abandoning Tomcat altogether since we couldn't keep our test environment 
running for more than 2 days without OutOfMemory problems while it would 
run for weeks on end with JRun3. Adding this line made all our problems 
go away, and we are now well on our way to completing our migration to 
Tomcat.

Michiel

-- 
Michiel Toneman  Software Engineer   Bibit Global Payment Services
Regulierenring 10  3981 LB  Bunnik       Michiel.Toneman@bibit.com
Tel. +31-30-6595168  Fax +31-30-6564464      http://www.bibit.com/


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


Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass

Posted by Adrian Barnett <ad...@abarnett.demon.co.uk>.
>> Ran out of memory last night again
>>
>> Set to 512m and ran out at 284m
>> Maybe I am missing a paramater in the tomcat setup on windows or  
>> something
>>
>> Frustrating
>>
>> James

I was having a memory leak using mod_jk2, and it was fixed by adding
request.registerRequests=false
to tomcat/conf/jk2.properties.
I don't know if this would work with mod_jk, but it might be worth a try.

Adrian


-- 
f y cn rd ths y cn gt a gd jb rt fpl dgm pvq!


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


Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass

Posted by Mark Lowe <ma...@boxstuff.com>.
I have this in our startup scripts

export CATALINA_OPTS="-Djava.awt.headless=true -Xmx128m -Xdebug"

Perhaps the debug argument might reveal something. I cant be much help  
on windows matters as I try not to get involved with anything like  
that.

My app is still running, but linux not windows so i don't know how far  
i can compare. I also have no idea about compiling jk under windows,  
i've always found that I've needed to compile jk often with the head  
version out of cvs (there's always a fix thats needed somewhere).

Mark

On 1 Jun 2004, at 13:05, James Sherwood wrote:

> Ran out of memory last night again
>
> Set to 512m and ran out at 284m
> Maybe I am missing a paramater in the tomcat setup on windows or  
> something
>
> Frustrating
>
> James
>
> ----- Original Message -----
> From: "Mark Lowe" <ma...@boxstuff.com>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Monday, May 31, 2004 4:04 PM
> Subject: Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass
>
>
>> 300 mb sounds a lot, i've got a hibernate and struts flavored app
>> running with a 128 limit, and thats being generous.
>>
>> I haven't measured anything but top looks happy, with 5.0.25 with jk  
>> to
>> apache 2.0.47. Had a bit of traffic this afternoon albeit nothing
>> heavy, had 5 simultaneously this afternoon. But nothing huge.
>>
>> Mark
>>
>> On 31 May 2004, at 17:54, James Sherwood wrote:
>>
>>> Thanks Mark,
>>>
>>> I have it currently running bypassing the mod_jk with rewrite to port
>>> 8080.
>>>
>>> The memory has ramped to 327 mb so far which is not anything to worry
>>> about.
>>>
>>> I had this problem on our linux box but I had forgotten the -server
>>> option
>>> and that took care of it.
>>> The problem is, windows doesnt accept -server.
>>>
>>> Ill continue to monitor it with the mod_jk bypass in.
>>>
>>>
>>> James
>>>
>>>
>>> ----- Original Message -----
>>> From: "Mark Lowe" <ma...@boxstuff.com>
>>> To: "Tomcat Users List" <to...@jakarta.apache.org>
>>> Sent: Monday, May 31, 2004 12:19 PM
>>> Subject: Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass
>>>
>>>
>>>> I've just set 5.0.25 up and it will run with mod_jk/1.2.3-dev and
>>>> Apache/2.0.47 , I'll see if i get the same thing happening.
>>>>
>>>> When i was having problems i was getting a decoding error written to
>>>> catalina log, which 5.0.24+ hasn't given me. 5.0.24 has been working
>>>> quite happily but the next man mentioned a session error so I took  
>>>> his
>>>> word for it and upgraded.
>>>>
>>>> You could have tomcat being served from an ip alias, but will depend
>>>> on
>>>> you configuration. And might take longer than getting jk sorted.
>>>>
>>>> For the moment I can just say i'll keep and eye on things and see if
>>>> the same happens to me.
>>>>
>>>> Mark
>>>>
>>>> On 31 May 2004, at 14:23, James Sherwood wrote:
>>>>
>>>>> There are no errors anywhere that I can find in any logs.  The  
>>>>> memory
>>>>> just
>>>>> slowly ramps up till an out of memory error happens.
>>>>>
>>>>> James
>>>>>
>>>>> ----- Original Message -----
>>>>> From: "Mark Lowe" <ma...@boxstuff.com>
>>>>> To: "Tomcat Users List" <to...@jakarta.apache.org>
>>>>> Sent: Monday, May 31, 2004 9:04 AM
>>>>> Subject: Re: Tomcat5/mod_jk Memory Leak/mod_jk bypass
>>>>>
>>>>>
>>>>>> What does your catalina log have to say for itself?
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On 31 May 2004, at 13:59, James Sherwood wrote:
>>>>>>
>>>>>>> As I posted before, I get a memory leak using mod_jk 1.2 with
>>>>>>> Tomcat
>>>>>>> 5.0.25
>>>>>>> and Apache 2.049
>>>>>>>
>>>>>>> I beleive it may be related to the mod_jk connector and since I  
>>>>>>> am
>>>>>>> not
>>>>>>> actually serving up anything with apache yet I want to just  
>>>>>>> bypass
>>>>>>> the
>>>>>>> connector for 1 site and hit tomcat directly. I have to use  
>>>>>>> apache
>>>>>>> for
>>>>>>> other
>>>>>>> things on the server so I cannot just use tomcat.
>>>>>>>
>>>>>>> Any idea the best route for this? (of course a fix for the leak  
>>>>>>> is
>>>>>>> the
>>>>>>> best
>>>>>>> route:)
>>>>>>> My route works but certian urls within the site do not
>>>>>>> work(although
>>>>>>> I
>>>>>>> think
>>>>>>> I could get them working).
>>>>>>>
>>>>>>> The way I have done it is this:
>>>>>>>
>>>>>>> <VirtualHost *>
>>>>>>>
>>>>>>> ServerName mysite.ca
>>>>>>>
>>>>>>> RewriteEngine on
>>>>>>>
>>>>>>> RewriteCond %{HTTP_HOST} ^www\.mysite\.ca$ [NC]
>>>>>>>
>>>>>>> RewriteRule ^(.*) http://localhost:8080$1 [p]
>>>>>>>
>>>>>>> </VirtualHost>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Thanks, James
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ----------------------------------------------------------------- 
>>>>>>> --
>>>>>>> --
>>>>>>> To unsubscribe, e-mail:  
>>>>>>> tomcat-user-unsubscribe@jakarta.apache.org
>>>>>>> For additional commands, e-mail:
>>>>>>> tomcat-user-help@jakarta.apache.org
>>>>>>>
>>>>>>
>>>>>>
>>>>>> ------------------------------------------------------------------ 
>>>>>> --
>>>>>> -
>>>>>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>>>>> For additional commands, e-mail:  
>>>>>> tomcat-user-help@jakarta.apache.org
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ------------------------------------------------------------------- 
>>>>> --
>>>>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>>>> For additional commands, e-mail:  
>>>>> tomcat-user-help@jakarta.apache.org
>>>>>
>>>>
>>>>
>>>> -------------------------------------------------------------------- 
>>>> -
>>>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>>> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>>>
>>>>
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>


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