When using JasperSoft Studio, receive a JAVA Heap Space Error

Document ID : KB000007352
Last Modified Date : 14/02/2018
Show Technical Document Details
Issue:

When using JasperSoft Studio, receive a JAVA Heap Space Error similar to the following:

java.lang.OutOfMemoryError: Java heap space

at java.util.Arrays.copyOf(Unknown Source)

at java.io.ByteArrayOutputStream.write(Unknown Source)

at sun.nio.cs.StreamEncoder.writeBytes(Unknown Source)

at sun.nio.cs.StreamEncoder.implWrite(Unknown Source)

at sun.nio.cs.StreamEncoder.write(Unknown Source)

at sun.nio.cs.StreamEncoder.write(Unknown Source)

at java.io.OutputStreamWriter.write(Unknown Source)

at java.io.Writer.write(Unknown Source)

Environment:
JasperSoft Studio 6.xAll Supported Operating Systems
Resolution:

Increase the JVM Heap Size allocated to JasperSoft Studio.

On the machine where JasperSoft Studio is installed, modify the 'Jaspersoft Studio Professional.ini' file.  This file is located in the root of the JasperStudio install directory (i.e. C:\Program Files\TIBCO\Jaspersoft Studio Professional-6.2.1.final).

Modify the -Xms and -Xmx lines to the following (assuming you have enough RAM available):

-Xms1024m

-Xmx4096m

If JasperSoft Studio is open when the change is made, a restart of JasperSoft Studio is required..