Description
During the deployment process of FineReport V11.0 on the server, an HTTP status 500 — Internal Server Error is displayed, as shown in the following figure.
Cause
In FineReport V11.0 and FineBI V5.1, Java Agent and JVMTI technologies have been introduced and used for AOP programming, protection of critical classes, and implementation of forced memory recycling.
The two technologies are both JVM Agents. The difference is that the former is implemented in Java, while the latter is implemented in C++. Therefore, in addition to JRE during the runtime, the tools.jar from JDK is also required (including tools such as the Java compiler and dynamic loading Agent).
tools.jar is a toolkit related to the platform. The version of tools.jar that can be used normally varies depending on the platform (such as the Windows system, the Linux system, and the OS X system) and the versions of the JRE. Therefore, you need to pay attention to the compatibility when using tools.jar.
Solution
Notes: 1. Tomcat is used as an example. For other containers, tools.jar also needs to be copied and pasted to the lib of the corresponding container.
2. The tools.jar in %JAVA_HOME%/jdk/lib is the file in the JAVA_HOME of the deployed server, instead of the development computer.
Copy the tools.jar in %JAVA_HOME%/jdk/lib and paste the JAR to the deployed server, namely the %TOMCAT_HOME%/lib or the %TOMCAT_HOME%/webapps/Project name/WEB_INF/lib, as shown in the following figure.
Notes
If the attach.dll file does not exist in the %JRE_HOME%/bin pointed to by the environment variable, you need to copy the attach.dll file in %JAVA_HOME%/jdk/jre/bin and paste the file to this path, as shown in the following figure.