Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 011B5D75E for ; Wed, 5 Sep 2012 18:19:20 +0000 (UTC) Received: (qmail 50255 invoked by uid 500); 5 Sep 2012 18:19:16 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 50210 invoked by uid 500); 5 Sep 2012 18:19:16 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 50200 invoked by uid 99); 5 Sep 2012 18:19:16 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Sep 2012 18:19:16 +0000 X-ASF-Spam-Status: No, hits=0.7 required=5.0 tests=RCVD_IN_DNSWL_NONE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [76.96.59.243] (HELO qmta13.westchester.pa.mail.comcast.net) (76.96.59.243) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Sep 2012 18:19:09 +0000 Received: from omta02.westchester.pa.mail.comcast.net ([76.96.62.19]) by qmta13.westchester.pa.mail.comcast.net with comcast id vR9s1j0040QuhwU5DWJrRQ; Wed, 05 Sep 2012 18:18:51 +0000 Received: from Christophers-MacBook-Pro.local ([69.143.109.145]) by omta02.westchester.pa.mail.comcast.net with comcast id vWJQ1j00738FjT13NWJRm0; Wed, 05 Sep 2012 18:18:26 +0000 Message-ID: <50479783.5040903@christopherschultz.net> Date: Wed, 05 Sep 2012 14:18:43 -0400 From: Christopher Schultz User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20120824 Thunderbird/15.0 MIME-Version: 1.0 To: Tomcat Users List Subject: Re: Facing Memory leak - 64 bit Tomcat 6.0.35 with windows 2008 R2(64 bit JVM 1.6.0_33) References: ,<50476C05.6030308@christopherschultz.net> <1346865475.2513.1428.camel@dellberry> In-Reply-To: <1346865475.2513.1428.camel@dellberry> X-Enigmail-Version: 1.4.4 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Tim, On 9/5/12 1:17 PM, Tim Watts wrote: > On Wed, 2012-09-05 at 12:16 -0400, PJ Delsh wrote: >> Shailendra, I'm not an expert, but when we had this same issue, >> we increased the Initial Memory Pool and Maximum Memory pool (XMS >> and XMX) in the Tomcat Monitor in Windows 2008.We also had a leak >> in some of our JSP files that was causing Tomcat to hang several >> times during business hours. We configured Tomcat so that >> VisualVM (which comes with the Java JDK) could monitor Tomcat >> memory usage. Then we took heap dumps, and analyzed them for >> leaks (Shallow Heap vs Retained Heap) using Eclipse Memory >> Analyzer. Once we fixed the leaks, Tomcat was stable.In the >> interim, if you have Tomcat running as a service in Windows, >> under the Recovery tab set the Tomcat service to restart >> automatically if it does stop. But if you have memory leaks, >> the Tomcat service probably will still be running but it won't >> be responding.You can also install more than one Tomcat on the >> same server, so if one goes down, the other will still be >> running. You would also have to configure Apache (or whatever) >> to work with more than one Tomcat.We also had issues with the >> Tomcat service crashing (eg Terminated Unsuccessfully) on >> Windows. After months of searching, we think the issue was >> having system.exit(0) in our code. > > System.exit(0) is the very definition of successful termination > although it certainly doesn't belong in your webapp's code. +1 >> The truth is that Tomcat is not written well enough to run on >> Windows. > > What rot. All the problems you mention above you traced back to > your application. Yet your conclusion is that Tomcat doesn't run > well on Windows. Really? Tomcat runs very well on Microsoft Windows. Poorly-written applications will fail under any environment. In the OP's case, I really believe the only problem is that the heap is too small when moving from a 32-bit to a 64-bit JVM, but we can't seem to get s response from the OP so I guess we'll never know. >> See what you can do to move your app to Linux. You will find >> many more Tomcat experts on Linux than on Windows. > > I myself have a strong preference for Linux but for reasons > unrelated to Tomcat. In reality, you'll find that most Tomcat > experts don't give a rat's hiney which OS it runs under. But they > may care which JVM you're using. I'm another Linux supporter and I'd hate to run Microsoft Windows as a server in general, but if you're stuck with it, Tomcat isn't going to be the problem. >> Tomcat is not like IIS. > True. > >> Developing for Tomcat on Windows is fine, but running production >> apps in Tomcat on Windows is a bad idea. I wish this was more >> widely known and publicized.-PJ > > Total BS. Agreed. PJ: care to cite any "widely known and publicized" references? Also, PJ, what makes you think that your experiences are anything like the OP's? You seem to be spouting "solutions" to problems that you do not understand. When the reported problem is "we are getting OOMEs", the solution is not automatically "you should switch to Linux because Tomcat sucks on Windows". It's inaccurate advice (Tomcat works find on Windows) and is very unlikely to solve the problem (whatever it is). - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://www.enigmail.net/ iEYEARECAAYFAlBHl4MACgkQ9CaO5/Lv0PAYmACdGQidM7rMSsG/+rZaA2P/zliB ibAAoIWe4z0Ifvy9h8WrYJdbZHvdc4Fp =9H6c -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org