- Java Heap Size error.
- Error: 'GC overhead limit exceeded'
- When refreshing a report in Crystal Reports for Enterprise, it generates a Java Heap Size error.
- When opening a report in Crystal Reports Viewer, it generates a Java Heap Size error.
- SAP Crystal Reports for Enterprise 4.0
- SAP Crystal Reports for Enterprise 4.1
- SAP Crystal Reports for Enterprise 4.2
- SAP Crystal Reports Viewer 2011
- SAP Crystal Reports Viewer 2013
- SAP Crystal Reports Viewer 2016
Reproducing the Issue
- In Crystal Reports for Enterprise, refresh a report; or in Crystal Reports Viewer, open a report.
- After some times, it generates a Java Heap Size error.
- The java heap space error received when opening or refreshing a report, occurs because Crystal Reports for Enterprise and Crystal Reports Viewer are ore... 32-bit Java applications. The maximum memory for the Java Virtual Machine (JVM) that can be assigned to the Java heap is 4GB.
- Out of the 4GB of memory, the MS Windows operating system uses around 2GB of this memory.
- Therefore only 2GB are left for the Java Virtual Machine (JVM). Out of this 2GB of memory, the JVM needs to have a continuous memory region for the heap, which result of a maximum amount of memory the JVM can use is between 1.3GB to 1.5GB.
- There is no option to increase the amount of memory that can be used by the application as it is a limitation of 32bit applications.
- In brief, Crystal Reports for Enterprise, and Crystal Reports Viewer, can use up to a maximum of 1.3 to 1.5GB of memory, and reports that requires more memory will generate a Java Heap Size memory error.
- Reduce the amount of memory the report uses, by modifying the report design:
- If the reports returns a large number of records, then the solution could be to filter the data to return a smaller data set.
- Look at the report design, and modify the report to improve the report performance.
See the following SAP Knowledge Base Article for suggestions on how to improve report performance, and by consequant reduce the amount of memory the report uses:
1636361 - How to design a report to improve performance in Crystal Reports?
CRFE, CR4E, CR for Enterprise, CR Viewer, java memory issue , KBA , BI-RA-CRE , Crystal Reports for Enterprise , BI-RA-CRV , SAP Crystal Reports Viewer , Problem
SAP Crystal Reports Viewer 2011 ; SAP Crystal Reports viewer 2013 ; SAP Crystal Reports viewer 2016