Overview
This article will introduce some errors caused by JAVA environment variable configuration problems and corresponding solutions.
Note: The required JDK version: JDK 1.8 and a minor version of JDK 8u102 or above.
Examples
An Error in Logs: Unsupported major.minor version 52.0
Problem 1: The startup has failed, resulting in a 404 error.Cause
JDK 1.7 and lower versions are not supported in FineBI from Sept. 2, 2020. Only JDK 1.8 is available.
Solution
The JDK version needs to be 1.8 and the minor version needs to be JDK 8u102 or above.
Problem 2: The corresponding plugin cannot be used when running FineBI.Cause
The JDK version of the plugin compilation is higher than that of running JAVA environment variable.
Solution
Replace other JDK version from FineBI official in JAVA environment with JDK 1.8.
Failed Startup: Fine assist start failed
Problem 1Description
There is a log error message: Caused by: com.sun.tools.attach.AttachNotSupportedException: no providers installed.
Cause
When you install JDK in the Windows system, an independent jre will be installed at the same time. There is no attach.dll file in the independently installed jre, but this file is needed for FineBI startup.
Solution
Use %JAVA_HOME%\jre to configure JRE_HOME.
Problem 2Description
There is a log error message: java.lang.UnsatisfiedLinkError: sun.tools.attach.LinuxVirtualMachine.isLinuxThreads()Z.
Cause
Use tools.jar of Linux when you deploy FineBI in Windows system.
Solution
Use %JAVA_HOME%\lib to obtain tools.jar and add it to webroot/WEB-INF/lib or tomcat/lib.
Problem 3Description
There is a log error message: Caused by: com.sun.tools.attach.AgentLoadException: Failed to load agent library.
Cause 1
There is something wrong in JDK, such as wrong bits or incomplete functions.
Solution: Use uname to obtain the version of the system and install the corresponding JDK version. Note: x86 refers to the system structure of intel. x86_64 is 64-bit and i586 is 32-bit.
Cause 2
There is something wrong in FineAssist_xx.so file, which cannot be loaded.
Solution: Retrieve FineAssist_xx.so file from core package. You need to reinstall so file in secure computers.
Problem 4Description
Other errors: com.sun.tools.attach.AttachNotSupportedException: Unable to open socket file: target process not responding or HotSpot VM not loaded.
This problem may not be caused by JDK.
Cause
You cannot add files to the /tmp directory. It may be because:
There are no permissions for ordinary users.
There is no space in the disk of /tmp.
Solution
Configure access to /tmp directory for ordinary users.
Clear the space of corresponding disk.
Problems in Some JDK Versions
1. Crash on Startup with JDK 1.8.0_65 or LowerDescription
There is an error in the log: java.lang.IllegalArgumentException: object is not an instance of declaring class.
Cause
bytebuddy versions are incompatible.
Solution
Upgrade other JDK versions to JDK 1.8.
2. Blank Preview Template in JDK 1.8.0_171Description
All templates are blank when you preview.
Cause
oracle 1.8.0_171_b11 will cause blank templates.
Solution
Upgrade JDK versions to 1.8 and the minor version to 8u102 or above.
Designating JDK Versions in Tomcat
On Windows System
Modify catalina.bat file in tomcat/bin directory. Take the deployment package as an example.
On Linux System
Modify catalina.sh file in tomcat/bin directory. Take the deployment package as an example.
To designate the JDK path in Linux deployment package, you must make sure it is added before first invoking JAVA_HOME and after defining CATALINA_HOME.
Other packages can be designated to JDK with the absolute path. There is no limit of CATALINA_HOME. You only need to add the deployment package before first invoking JAVA_HOME.