Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / October 2005

Tip: Looking for answers? Try searching our database.

Out of memory errors

Thread view: 
John Smith - 03 Oct 2005 12:19 GMT
I am having a nightmare with memory problems first it was heap space, I
fixed the leaks in our code and now it fails in the compiler thread:

Heap
PSYoungGen      total 58240K, used 38053K [0x31580000, 0x36ad0000,
0x36ad0000)
 eden space 29120K, 100% used [0x31580000,0x331f0000,0x331f0000)
 from space 29120K, 30% used [0x331f0000,0x33aa9798,0x34e60000)
 to   space 29120K, 0% used [0x34e60000,0x34e60000,0x36ad0000)
PSOldGen        total 33856K, used 23191K [0x06ad0000, 0x08be0000,
0x31580000)
 object space 33856K, 68% used [0x06ad0000,0x08175f90,0x08be0000)
PSPermGen       total 16384K, used 8523K [0x02ad0000, 0x03ad0000,
0x06ad0000)
 object space 16384K, 52% used [0x02ad0000,0x03322c60,0x03ad0000)
[GC [PSYoungGen: 38053K->11357K(56448K)] 61245K->34549K(90304K), 0.0548500
secs]
Heap after GC invocations=3896:
Heap
PSYoungGen      total 56448K, used 11357K [0x31580000, 0x36910000,
0x36ad0000)
 eden space 29120K, 0% used [0x31580000,0x31580000,0x331f0000)
 from space 27328K, 41% used [0x34e60000,0x35977760,0x36910000)
 to   space 28224K, 0% used [0x331f0000,0x331f0000,0x34d80000)
PSOldGen        total 33856K, used 23191K [0x06ad0000, 0x08be0000,
0x31580000)
 object space 33856K, 68% used [0x06ad0000,0x08175f90,0x08be0000)
PSPermGen       total 16384K, used 8523K [0x02ad0000, 0x03ad0000,
0x06ad0000)
 object space 16384K, 52% used [0x02ad0000,0x03322c60,0x03ad0000)
}  {Heap before GC invocations=3897:
Heap
PSYoungGen      total 56448K, used 40477K [0x31580000, 0x36910000,
0x36ad0000)
 eden space 29120K, 100% used [0x31580000,0x331f0000,0x331f0000)
 from space 27328K, 41% used [0x34e60000,0x35977760,0x36910000)
 to   space 28224K, 0% used [0x331f0000,0x331f0000,0x34d80000)
PSOldGen        total 33856K, used 23191K [0x06ad0000, 0x08be0000,
0x31580000)
 object space 33856K, 68% used [0x06ad0000,0x08175f90,0x08be0000)
PSPermGen       total 16384K, used 8524K [0x02ad0000, 0x03ad0000,
0x06ad0000)
 object space 16384K, 52% used [0x02ad0000,0x03323010,0x03ad0000)
[GC [PSYoungGen: 40477K->13701K(57344K)] 63669K->36893K(91200K), 0.0660287
secs]
Heap after GC invocations=3897:
Heap
PSYoungGen      total 57344K, used 13701K [0x31580000, 0x36810000,
0x36ad0000)
 eden space 29120K, 0% used [0x31580000,0x31580000,0x331f0000)
 from space 28224K, 48% used [0x331f0000,0x33f516c8,0x34d80000)
 to   space 26944K, 0% used [0x34dc0000,0x34dc0000,0x36810000)
PSOldGen        total 33856K, used 23191K [0x06ad0000, 0x08be0000,
0x31580000)
 object space 33856K, 68% used [0x06ad0000,0x08175f90,0x08be0000)
PSPermGen       total 16384K, used 8524K [0x02ad0000, 0x03ad0000,
0x06ad0000)
 object space 16384K, 52% used [0x02ad0000,0x03323010,0x03ad0000)
}
Exception in thread "CompilerThread1" java.lang.OutOfMemoryError: requested
310608 bytes for Chunk::
new. Out of swap space?

The machine was started with -Xmx512m and as you can see it is no where near
that limit. The machine is windows 2003 server with java  verson is :
java version "1.5.0_05"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode, sharing)

The machine has 3gb of memory and at the time it fails task manager says it
is using just 350m

Any help would be gratefully appreciated

Thanks

Jon
Roedy Green - 04 Oct 2005 10:27 GMT
>Any help would be gratefully appreciated

I presume you are using Windows of some sort.

Go into settings | control panel | system | advanced | performance
options | change

and make sure you have a decently fat swapfile defined.  After you
have changed that you might want to run PageDefrag from
http://sysinternals.com/ntw2k/information.shtml
to defrag it.
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.