Problem
WBEM-based KMs/ETLs (EMC Disk Arrays, EMC Unity, HP 3PAR etc.) stop working with Java 17+ and the following exception is observed in the logs:
Caused by: java.lang.IllegalAccessException: class org.sblim.cimclient.internal.http.HttpSocketFactory cannot access class sun.security.ssl.SunJSSE (in module java.base) because module java.base does not export sun.security.ssl to unnamed module @4e6ffbb4
Solution
Follow these steps to resume the monitoring:
-
Download the appropriate Troubleshooting Tool from Sentry’s Troubleshooting Tools. In this example, we are using the Troubleshooting Tool for HP 3PAR.
-
Use the same Java version to run the tool:
c:\Java\jdk-17.0.3+7\bin>java -version openjdk version "17.0.3" 2022-04-19 OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7) OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode, sharing)
with the following argument: –add-opens java.base/sun.security.ssl=ALL-UNNAMED:
C:\Java\jdk-17.0.3+7\bin>java --add-opens java.base/sun.security.ssl=ALL-UNNAMED -jar "D:\Support Diags\TroubleShooting-Tools-for-HP3PAR-1.2.00.jar"
-
Select at least 1 request and click the Test Connection button.
-
Once the data collect returns no exception as shown in the Result table (see above), follow one of the two procedures detailed below according to your environment.
For KMs
-
Edit your policy and in the Advanced Settings section, add the following configuration variable:
collectionHubAdditionalArgs with the following value: –add-opens java.base/sun.security.ssl=ALL-UNNAMED
-
Apply the policy and restart your PATROL Agent (mandatory).
-
Make sure the following Java process now has the argument we’ve just added, for example:
ProcessId : 30384 ParentProcessId : 46636 Name : java.exe commandline : "C:\Java\jdk-11.0.8\bin\java.exe" -Xms128m -Xmx512m --add-opens java.base/sun.security.ssl=ALL-UNNAMED -jar "C:\BMCSoftware\Patrol3\bin\SEN_HP3P_matsya-core-java.jar" PeakWorkingSetSize : 189624 PageFileUsage : 251100 PageFaults : 129991 ThreadCount : 24
For ETLs
-
As a workaround, add these lines to the /opt/bmc/BCO/customenv.sh file:
SCHEDULER_JAVA_OPTS="$SCHEDULER_JAVA_OPTS --add-opens java.base/sun.security.ssl=ALL-UNNAMED" export SCHEDULER_JAVA_OPTS
-
After the change restart the scheduler and verify that it has been added:
cpit@BCO]$ ps -ef |grep scheduler cpit 2470 1 3 16:29 pts/1 00:00:39 /opt/bmc/BCO/jre/bin/java -Dcpit.component=scheduler -Xms1024m -Xmx1024m -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/opt/bmc/BCO/heapdump/scheduler.hprof -Dcpit.tls.auth=false -Dcpit.tls.internal=false -Djava.security.krb5.conf= -Djava.awt.headless=true -Djava.io.tmpdir=/opt/bmc/BCO/temp -Dfile.encoding=UTF-8 -server --add-opens java.base/sun.security.ssl=ALL-UNNAMED -Dcpit.properties=/opt/bmc/BCO/scheduler/conf/cpit.properties -cp /opt/bmc/BCO/scheduler/classes:/opt/bmc/BCO/scheduler/lib/*:/opt/bmc/BCO/scheduler/libext/*: com.neptuny.scheduler.Scheduler
For additinal information, refer to a related article in the BMC Community.
Note: If the platform you are using is supported by the Storage Analyzer KM or the Storage - All-in-One Extractor Service and there is an equivalent REST API version, please consider moving to that version. Fore more details on supported platforms, see the Storage Intelligence Adapters - Reference.
Related Topics
- WBEM-Based Connectors Stopped Working
- KMs Report "Collection Hub is not started. Cannot send the query"
- CIM_ERR_FAILED Errors Occur When Running EMC WBEM-Based ETLs with Java v11.0.15 or Newer
- Monitoring Studio X Unexpectedly Hangs or Consumes High CPU When Running a JRE Higher Than 8
- Troubleshooting WMI-Based Connectors