Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #27897 > unrolled thread
| Started by | fredliu@google.com |
|---|---|
| First post | 2014-03-28 16:48 -0700 |
| Last post | 2014-03-28 21:59 -0400 |
| Articles | 12 — 4 participants |
Back to article view | Back to comp.lang.java.programmer
Java PermGen out of memory exception fredliu@google.com - 2014-03-28 16:48 -0700
Re: Java PermGen out of memory exception Arne Vajhøj <arne@vajhoej.dk> - 2014-03-28 20:23 -0400
Re: Java PermGen out of memory exception Jeff Higgins <jeff@invalid.invalid> - 2014-03-28 22:39 -0400
Re: Java PermGen out of memory exception Jeff Higgins <jeff@invalid.invalid> - 2014-03-28 22:53 -0400
Re: Java PermGen out of memory exception Jeff Higgins <jeff@invalid.invalid> - 2014-03-28 23:04 -0400
Re: Java PermGen out of memory exception Arne Vajhøj <arne@vajhoej.dk> - 2014-03-28 23:14 -0400
Re: Java PermGen out of memory exception Jeff Higgins <jeff@invalid.invalid> - 2014-03-29 09:02 -0400
Re: Java PermGen out of memory exception Jeff Higgins <jeff@invalid.invalid> - 2014-03-29 09:21 -0400
Re: Java PermGen out of memory exception Arne Vajhøj <arne@vajhoej.dk> - 2014-03-29 09:35 -0400
Re: Java PermGen out of memory exception Jeff Higgins <jeff@invalid.invalid> - 2014-03-29 10:32 -0400
Re: Java PermGen out of memory exception Roedy Green <see_website@mindprod.com.invalid> - 2014-03-28 17:42 -0700
Re: Java PermGen out of memory exception Arne Vajhøj <arne@vajhoej.dk> - 2014-03-28 21:59 -0400
| From | fredliu@google.com |
|---|---|
| Date | 2014-03-28 16:48 -0700 |
| Subject | Java PermGen out of memory exception |
| Message-ID | <f4dc7b5d-ac9b-4d54-944a-78f29e1e83d1@googlegroups.com> |
Hi,
I'm getting the PermGen exception from our web service. Just want to check other than analyzing through memory tools, are there any known bad practices which may cause PermGen memory leak? Thanks
The code of the sevlet
https://cs.corp.google.com/#piper///depot/google3/java/com/google/corp/bizapps/rews/spacesaver/web/nanny/BookingRemoverServlet.java
I've bumped up the memory size but the issue still exists.
"-XX:MaxPermSize=160m",
E0327 16:52:17.790999 56 GSE worker #22 HttpConnectionImpl.run caught a throwable
java.lang.OutOfMemoryError: PermGen space
at java.lang.ClassLoader.defineClass(ClassLoader.java:795)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)
at java.net.URLClassLoader.access$100(URLClassLoader.java:71)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:427)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.ja
[toc] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2014-03-28 20:23 -0400 |
| Message-ID | <53361271$0$301$14726298@news.sunsite.dk> |
| In reply to | #27897 |
On 3/28/2014 7:48 PM, fredliu@google.com wrote: > I'm getting the PermGen exception from our web service. Just want to check other than analyzing through memory tools, are there any known bad practices which may cause PermGen memory leak? Thanks > > The code of the sevlet > https://cs.corp.google.com/#piper///depot/google3/java/com/google/corp/bizapps/rews/spacesaver/web/nanny/BookingRemoverServlet.java > > I've bumped up the memory size but the issue still exists. > "-XX:MaxPermSize=160m", > > E0327 16:52:17.790999 56 GSE worker #22 HttpConnectionImpl.run caught a throwable > java.lang.OutOfMemoryError: PermGen space > at java.lang.ClassLoader.defineClass(ClassLoader.java:795) PermGen is used for classs definitions. If you are leaking it then it is often because you are dynamically generating classes and loading them continuously. But maybe you are not leaking but just need a lot. 160 MB is not that much. You could try with 300 MN and see if the app can keep running. Arne
[toc] | [prev] | [next] | [standalone]
| From | Jeff Higgins <jeff@invalid.invalid> |
|---|---|
| Date | 2014-03-28 22:39 -0400 |
| Message-ID | <lh5bss$hf8$1@dont-email.me> |
| In reply to | #27898 |
On 03/28/2014 08:23 PM, Arne Vajhøj wrote: > On 3/28/2014 7:48 PM, fredliu@google.com wrote: >> I'm getting the PermGen exception from our web service. > But maybe you are not leaking but just need a lot. This thread led me here. Thanks. <http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/toc.html>
[toc] | [prev] | [next] | [standalone]
| From | Jeff Higgins <jeff@invalid.invalid> |
|---|---|
| Date | 2014-03-28 22:53 -0400 |
| Message-ID | <lh5cmm$ofq$1@dont-email.me> |
| In reply to | #27902 |
On 03/28/2014 10:39 PM, Jeff Higgins wrote: > On 03/28/2014 08:23 PM, Arne Vajhøj wrote: >> On 3/28/2014 7:48 PM, fredliu@google.com wrote: >>> I'm getting the PermGen exception from our web service. >> But maybe you are not leaking but just need a lot. > > This thread led me here. Thanks. > <http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/toc.html> > Generally <http://docs.oracle.com/javase/7/docs/webnotes/tsg/> Specifically <http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/memleaks.html>
[toc] | [prev] | [next] | [standalone]
| From | Jeff Higgins <jeff@invalid.invalid> |
|---|---|
| Date | 2014-03-28 23:04 -0400 |
| Message-ID | <lh5dbn$rpj$1@dont-email.me> |
| In reply to | #27903 |
On 03/28/2014 10:53 PM, Jeff Higgins wrote: > On 03/28/2014 10:39 PM, Jeff Higgins wrote: >> On 03/28/2014 08:23 PM, Arne Vajhøj wrote: >>> On 3/28/2014 7:48 PM, fredliu@google.com wrote: >>>> I'm getting the PermGen exception from our web service. >>> But maybe you are not leaking but just need a lot. >> >> This thread led me here. Thanks. >> <http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/toc.html> >> > Generally <http://docs.oracle.com/javase/7/docs/webnotes/tsg/> > Specifically > <http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/memleaks.html> > > Well, it seems the Java 8 docs are easier to get to: <http://docs.oracle.com/javase/8/docs/> <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/index.html> <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/memleaks.html#sthref38>
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2014-03-28 23:14 -0400 |
| Message-ID | <53363a80$0$301$14726298@news.sunsite.dk> |
| In reply to | #27904 |
On 3/28/2014 11:04 PM, Jeff Higgins wrote: > On 03/28/2014 10:53 PM, Jeff Higgins wrote: >> On 03/28/2014 10:39 PM, Jeff Higgins wrote: >>> On 03/28/2014 08:23 PM, Arne Vajhøj wrote: >>>> On 3/28/2014 7:48 PM, fredliu@google.com wrote: >>>>> I'm getting the PermGen exception from our web service. >>>> But maybe you are not leaking but just need a lot. >>> >>> This thread led me here. Thanks. >>> <http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/toc.html> >>> >> Generally <http://docs.oracle.com/javase/7/docs/webnotes/tsg/> >> Specifically >> <http://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/memleaks.html> >> >> >> > Well, it seems the Java 8 docs are easier to get to: > <http://docs.oracle.com/javase/8/docs/> > <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/index.html> > <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/memleaks.html#sthref38> Hmm. I thought that permgen was gone in Java 8?? Arne
[toc] | [prev] | [next] | [standalone]
| From | Jeff Higgins <jeff@invalid.invalid> |
|---|---|
| Date | 2014-03-29 09:02 -0400 |
| Message-ID | <lh6gd2$r63$1@dont-email.me> |
| In reply to | #27905 |
On 03/28/2014 11:14 PM, Arne Vajhøj wrote: > On 3/28/2014 11:04 PM, Jeff Higgins wrote: >> Well, it seems the Java 8 docs are easier to get to: >> <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/memleaks.html#sthref38> >> > > Hmm. > > I thought that permgen was gone in Java 8?? > ? According to JEP 122 removing the permgen space was a funded project. Maybe that didn't extend to updating the documentation.
[toc] | [prev] | [next] | [standalone]
| From | Jeff Higgins <jeff@invalid.invalid> |
|---|---|
| Date | 2014-03-29 09:21 -0400 |
| Message-ID | <lh6hga$397$1@dont-email.me> |
| In reply to | #27906 |
On 03/29/2014 09:02 AM, Jeff Higgins wrote: > On 03/28/2014 11:14 PM, Arne Vajhøj wrote: >> On 3/28/2014 11:04 PM, Jeff Higgins wrote: > >>> Well, it seems the Java 8 docs are easier to get to: >>> <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/memleaks.html#sthref38> >>> >>> >> >> Hmm. >> >> I thought that permgen was gone in Java 8?? >> > ? According to JEP 122 removing the permgen space was a funded project. > Maybe that didn't extend to updating the documentation. > Ah. Current state is listed as Funded, not Complete. <http://openjdk.java.net/jeps/122> See: Process States <http://openjdk.java.net/jeps/1>
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2014-03-29 09:35 -0400 |
| Message-ID | <5336cc2a$0$304$14726298@news.sunsite.dk> |
| In reply to | #27907 |
On 3/29/2014 9:21 AM, Jeff Higgins wrote: > On 03/29/2014 09:02 AM, Jeff Higgins wrote: >> On 03/28/2014 11:14 PM, Arne Vajhøj wrote: >>> On 3/28/2014 11:04 PM, Jeff Higgins wrote: >> >>>> Well, it seems the Java 8 docs are easier to get to: >>>> <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/memleaks.html#sthref38> >>>> >>>> >>>> >>> >>> Hmm. >>> >>> I thought that permgen was gone in Java 8?? >>> >> ? According to JEP 122 removing the permgen space was a funded project. >> Maybe that didn't extend to updating the documentation. >> > Ah. Current state is listed as Funded, not Complete. > <http://openjdk.java.net/jeps/122> > See: Process States > <http://openjdk.java.net/jeps/1> That document also has: "Updated 2012/12/4" And http://www.oracle.com/technetwork/java/javase/8-whats-new-2157071.html states: <quote> * HotSpot ... * Removal of PermGen. </quote> Arne
[toc] | [prev] | [next] | [standalone]
| From | Jeff Higgins <jeff@invalid.invalid> |
|---|---|
| Date | 2014-03-29 10:32 -0400 |
| Message-ID | <lh6ll1$1h0$1@dont-email.me> |
| In reply to | #27908 |
On 03/29/2014 09:35 AM, Arne Vajhøj wrote: > On 3/29/2014 9:21 AM, Jeff Higgins wrote: >> On 03/29/2014 09:02 AM, Jeff Higgins wrote: >>> On 03/28/2014 11:14 PM, Arne Vajhøj wrote: >>>> On 3/28/2014 11:04 PM, Jeff Higgins wrote: >>> >>>>> Well, it seems the Java 8 docs are easier to get to: >>>>> <http://docs.oracle.com/javase/8/docs/technotes/guides/tsgvm/memleaks.html#sthref38> >>>>> >>>>> >>>>> >>>>> >>>> >>>> Hmm. >>>> >>>> I thought that permgen was gone in Java 8?? >>>> >>> ? According to JEP 122 removing the permgen space was a funded project. >>> Maybe that didn't extend to updating the documentation. >>> >> Ah. Current state is listed as Funded, not Complete. >> <http://openjdk.java.net/jeps/122> >> See: Process States >> <http://openjdk.java.net/jeps/1> > > That document also has: > > "Updated 2012/12/4" > > And > http://www.oracle.com/technetwork/java/javase/8-whats-new-2157071.html > states: > > <quote> > * HotSpot > ... > * Removal of PermGen. > </quote> > Yep. I guess that the third "Impact" listed at the bottom of the page: "Documentation: References to the permanent generation will need to be removed." is one item that keeps the page from being updated with a status of "Complete".
[toc] | [prev] | [next] | [standalone]
| From | Roedy Green <see_website@mindprod.com.invalid> |
|---|---|
| Date | 2014-03-28 17:42 -0700 |
| Message-ID | <3m5cj99gh36v61l5q879k9mk548biese65@4ax.com> |
| In reply to | #27897 |
On Fri, 28 Mar 2014 16:48:29 -0700 (PDT), fredliu@google.com wrote, quoted or indirectly quoted someone who said : >I'm getting the PermGen exception see http://mindprod.com/packratting.html -- Roedy Green Canadian Mind Products http://mindprod.com "A great lathe operator commands several times the wage of an average lathe operator, but a great writer of software code is worth 10,000 times the price of an average software writer." ~ Bill Gates
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2014-03-28 21:59 -0400 |
| Message-ID | <53362910$0$293$14726298@news.sunsite.dk> |
| In reply to | #27899 |
On 3/28/2014 8:42 PM, Roedy Green wrote: > On Fri, 28 Mar 2014 16:48:29 -0700 (PDT), fredliu@google.com wrote, > quoted or indirectly quoted someone who said : > >> I'm getting the PermGen exception > > see http://mindprod.com/packratting.html Link does not work. http://mindprod.com/jgloss/packratting.html does. But since the text does not relate to PermGen, then it is irrelevant anyway. Arne
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.java.programmer
csiph-web