Can someone tell me if I am editing the correct file (as outlined below) to
increase the memory allocated to GeoServer?  I have been increasing the
memory settings in the wrapper.conf file, but continue to have the
OutOfMemoryError.  Based on what I see in the log files and the resource
monitor in Windows, the memory being used is far less than I have allocated.
Am I editing the wrong file?

 

Thanks,

 

Jerome Wendell

 

 

From: Jerome A. Wendell [mailto:jawend...@suddenlink.net] 
Sent: Thursday, January 30, 2014 10:49 AM
To: geoserver-users@lists.sourceforge.net
Subject: [Geoserver-users] java.lang.OutOfMemoryError: Java heap space -
Error while printing

 

I am currently using the standalone MapFish printing module V2.0, with
GeoServer V2.4.3 on Windows Server 2008 R2.  When I try to print layers from
public servers (osm and WMTS) and overlay WMS layers from our GeoServer, I
get the following error message:

 

                "Error while adding a PDF elementjava.io.IOException: The
byte array is not a recognized imageformat"

 

When I print the public layers alone, there is no problem and no errors.
When I print the WMS layers from our GeoServer without the public layers,
there is no problem and no errors.  And, when I print the WMS layers from
our GeoServer first and then print the public layers, there is no problem
and no errors.  However, I need to print the public layers first because
they are my base layers, and the WMS layers are overlay layers.

 

I know this sounds like a MapFish printing problem, but I looked further
back in the GeoServer logs, and I found the following error message:

 

                java.lang.OutOfMemoryError: Java heap space

 

It seems the error that I get when printing is caused by the memory error.
I am running GeoServer and the MapFish printing module in the same
container.  I have searched on the web for this error, and have found a
number of posts on this topic, and as a result I have changed the contents
of the wrapper.conf file in the GeoServer 2.4.3\wrapper directory to contain
the following:

 

# Java Additional Parameters

wrapper.java.additional.1=-Djetty.home=.

wrapper.java.additional.2=-DGEOSERVER_DATA_DIR="%GEOSERVER_DATA_DIR%"

wrapper.java.additional.3=-server

wrapper.java.additional.4=-Xmx512M -Xms512m

wrapper.java.additional.5=-XX:SoftRefLRUPolicyMSPerMB=36000

wrapper.java.additional.6=-XX:MaxPermSize=256m

wrapper.java.additional.7=-XX:NewRatio=2

wrapper.java.additional.8=-XX:+UseParallelGC

 

I have highlighted the lines that I added.  There are also some additional
lines in the wrapper.conf file that follow the section above, that based on
my limited knowledge of Java seem to be in conflict with a couple of the
settings above.  The lines that I am referring to were in the original file,
and are as follows:

 

# Initial Java Heap Size (in MB)

wrapper.java.initmemory=48

 

# Maximum Java Heap Size (in MB)

wrapper.java.maxmemory=128

 

Any suggestions of how to resolve this error with using the printing module
in the same container as GeoServer would be greatly appreciated.

 

Thanks,

 

Jerome Wendell

 

------------------------------------------------------------------------------
WatchGuard Dimension instantly turns raw network data into actionable 
security intelligence. It gives you real-time visual feedback on key
security issues and trends.  Skip the complicated setup - simply import
a virtual appliance and go from zero to informed in seconds.
http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to