Error when running reports in Jasperserver:Handler dispatch failed; nested exception is java.lang.NoClassDefFoundError: Could not initialize class java.awt.Color

Posted on by By admin, in Jaspersoft | 0

Error when running reports in Jasperserver:Handler dispatch failed; nested exception is java.lang.NoClassDefFoundError: Could not initialize class java.awt.Color

Issue description:

When trying to run any report on a server, the following error is thrown:

Troubleshooting:

This error is normally associated with a JVM not being started on a Linux machine in AWT headless mode. JasperReports Server doesn’t provide a virtual X frame buffer on Linux. To prevent Java from trying to connect to an X-Server for image processing in JRS, please modify your application server’s startup script to include the following JAVA_OPTS

-Djava.awt.headless=true 

Steps:

  1. Open the following file in a text editor:
    /tomcat_home/bin/setenv.sh
  2. In the setenv.sh file, add the following options for JAVA_OPTS near the top of the file:
    -Djava.awt.headless=true
  3. Save your changes and restart Tomcat for this change to take effect.

Thank You,
Archana Verma
Helical IT Solutions

logo

Free Open Source BI Platform

logo
  • AI-Powered Analytics
  • Embedded Analytics
  • Single Sign-On (SSO)
  • Multi-Tenancy
  • Paginated Canned Reporting
  • Interactive Dashboard
  • White Labeling
0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments