On starting CA APMSQL Server, getting the error message: "Unsupported major.minor version 52.0."

book

Article ID: 6673

calendar_today

Updated On:

Products

APP PERF MANAGEMENT CA Application Performance Management Agent (APM / Wily / Introscope) CUSTOMER EXPERIENCE MANAGER INTROSCOPE

Issue/Introduction

Starting the APMSQL server on the Enterprise Manager generates the following  message and APMSQL fails to begin successfully,

Exception in thread "main" java.lang.UnsupportedClassVersionError: com/ca/apm/server/teiid/APMSQLServer : Unsupported major.minor version 52.0

        at java.lang.ClassLoader.defineClass1(Native Method)

        at java.lang.ClassLoader.defineClass(Unknown Source)

        at java.security.SecureClassLoader.defineClass(Unknown Source)

        at java.net.URLClassLoader.defineClass(Unknown Source)

        at java.net.URLClassLoader.access$100(Unknown Source)

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.security.AccessController.doPrivileged(Native Method)

        at java.net.URLClassLoader.findClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        at sun.launcher.LauncherHelper.checkAndLoadMain(Unknown Source)

Exception in thread "main" java.lang.UnsupportedClassVersionError: com/ca/apm/server/teiid/APMSQLServer : Unsupported major.minor version 52.0

        at java.lang.ClassLoader.defineClass1(Native Method)

        at java.lang.ClassLoader.defineClass(Unknown Source)

        at java.security.SecureClassLoader.defineClass(Unknown Source)

        at java.net.URLClassLoader.defineClass(Unknown Source)

        at java.net.URLClassLoader.access$100(Unknown Source)

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.security.AccessController.doPrivileged(Native Method)

        at java.net.URLClassLoader.findClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

       at sun.launcher.LauncherHelper.checkAndLoadMain(Unknown Source)

 

Cause

 APMSQL Server requires using Java 1.8.  The issue occurs because the APMSQL Server start script is not finding Java 1.8 but another version.

Environment

APM 10.5.1

Resolution

You have a few choices for resolution.

1. If the default Java version on your server is not Java 1.8,  then download and upgrade it to the latest Java 1.8 release.

2.  Modify the script to point to the JRE of the Enterprise Manager installation.  This is usually found in <EM Home>\\jre\\bin on Windows and <EM Home>/jre/bin folder in a Linux installation.

Here are the changes in the Windows bat file. (Note that the Linux changes are the same except the syntax.)

In apmsql.bat on line 71 you will find:

if "%JAVACMD%"=="" set JAVACMD=java

Change to include the EM JRE Java version

if "%JAVACMD%"=="" set JAVACMD="C:\CA APM\Introscope10.5.1.8\jre\bin\java"

3. Set JAVACMD="C:\CA APM\Introscope10.5.1.8\jre\bin\java" then try running the CA APMSQL Server again.

 

 

Additional Information

From the 10.5 APM Guide: "Install and Configure CA APMSQL Server" and "CA APMSQL Cookbook."