Consistent failure ...
[2019-03-27T14:35:13.786Z] com.sun.tools.attach.AttachOperationFailedException: AttachOperationFailedException from target: ATTACH_ERR AttachOperationFailedException in startLocalManagementAgent: startLocalManagementAgent error starting agent:class com.ibm.tools.attach.target.IbmAttachOperationFailedException startLocalManagementAgent cannot access startLocalManagementAgent
[2019-03-27T14:35:13.786Z] at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.parseResponse(OpenJ9VirtualMachine.java:335)
[2019-03-27T14:35:13.786Z] at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.startLocalManagementAgent(OpenJ9VirtualMachine.java:525)
[2019-03-27T14:35:13.786Z] at GetPackageBootLoaderChildLayer.main(GetPackageBootLoaderChildLayer.java:46)
[2019-03-27T14:35:13.786Z] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2019-03-27T14:35:13.786Z] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[2019-03-27T14:35:13.786Z] at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[2019-03-27T14:35:13.786Z] at java.base/java.lang.reflect.Method.invoke(Method.java:567)
[2019-03-27T14:35:13.786Z] at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
[2019-03-27T14:35:13.786Z] at java.base/java.lang.Thread.run(Thread.java:825)
... observed in test https://github.com/ibmruntimes/openj9-openjdk-jdk12/blob/openj9/test/jdk/java/lang/Class/GetPackageBootLoaderChildLayer.java.
See consoleText.txt.
Test excluded via: https://github.com/AdoptOpenJDK/openjdk-tests/pull/1040
Might be related to https://github.com/eclipse/openj9/issues/3048#issuecomment-425056934
@ben-walsh did this test pass with OpenJ9 JDK 8/11?
@JasonFengJ9 Not tried. I'll schedule a couple of appropriate Grinder jobs.
JDK8+OJ9 latest nightly - https://ci.adoptopenjdk.net/view/Test_grinder/job/Grinder/1380
JDK11+OJ9 latest nightly - https://ci.adoptopenjdk.net/view/Test_grinder/job/Grinder/1381
Just realised the test isn't present in JDK8.
It does fail in same way with JDK11 - consoleText.txt
After running a few test jobs, I've found this issue to be fixed for openjdk_x86-64_osx and openjdk_x86-64_linux but it appears that openjdk_x86-64_windows is still causing problems
https://hyc-runtimes-jenkins.swg-devops.com/view/Test_grinder/job/Grinder_Advanced/348/consoleText
The error is also different to the last issue, now throwing a AttachNotSupportedException
@M-Davies - thanks for looking at this! Can I ask that you paste the relevant piece of consoleText into issues, as the Grinder jobs are transient (history is not kept long on Jenkins) and the hyc-runtimes server is internal (not accessible to developers outside of Runtimes).
Of course. My apologies
``[2019-07-19T12:41:14.600Z] STDERR:
[2019-07-19T12:41:14.600Z] com.sun.tools.attach.AttachNotSupportedException: target not found
[2019-07-19T12:41:14.600Z] at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.attachTargetImpl(OpenJ9VirtualMachine.java:151)
[2019-07-19T12:41:14.600Z] at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.lambda$attachTarget$1(OpenJ9VirtualMachine.java:129)
[2019-07-19T12:41:14.600Z] at com.ibm.tools.attach.attacher.OpenJ9VirtualMachine$$Lambda$28.000000002F690E10.run(Unknown Source)
[2019-07-19T12:41:14.600Z] at java.base/java.security.AccessController.doPrivileged(AccessController.java:703)
[2019-07-19T12:41:14.600Z] at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.attachTarget(OpenJ9VirtualMachine.java:131)
[2019-07-19T12:41:14.600Z] at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9AttachProvider.attachVirtualMachine(OpenJ9AttachProvider.java:64)
[2019-07-19T12:41:14.600Z] at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9AttachProvider.attachVirtualMachine(OpenJ9AttachProvider.java:48)
[2019-07-19T12:41:14.600Z] at jdk.attach/com.sun.tools.attach.VirtualMachine.attach(VirtualMachine.java:207)
[2019-07-19T12:41:14.600Z] at GetPackageBootLoaderChildLayer.main(GetPackageBootLoaderChildLayer.java:45)
[2019-07-19T12:41:14.600Z] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2019-07-19T12:41:14.600Z] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[2019-07-19T12:41:14.600Z] at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[2019-07-19T12:41:14.600Z] at java.base/java.lang.reflect.Method.invoke(Method.java:566)
[2019-07-19T12:41:14.600Z] at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
[2019-07-19T12:41:14.600Z] at java.base/java.lang.Thread.run(Thread.java:831)
[2019-07-19T12:41:14.600Z]
[2019-07-19T12:41:14.600Z] JavaTest Message: Test threw exception: com.sun.tools.attach.AttachNotSupportedException: target not found
[2019-07-19T12:41:14.600Z] JavaTest Message: shutting down test
[2019-07-19T12:41:14.600Z]
[2019-07-19T12:41:14.600Z] STATUS:Failed.main' threw exception: com.sun.tools.attach.AttachNotSupportedException: target not found
@pdbain-ibm @JasonFengJ9
Two potential problems in https://github.com/ibmruntimes/openj9-openjdk-jdk12/blob/openj9/test/jdk/java/lang/Class/GetPackageBootLoaderChildLayer.java:
String vmid = "" + ProcessHandle.current().pid();; The vmid is usually, but not necessarily the pid.VirtualMachine vm = VirtualMachine.attach(vmid);; VMs cannot attach to themselves without setting the system property -Djdk.attach.allowAttachSelf=true.@M-Davies would you kindly run with logging enabled? Please set system property -Dcom.ibm.tools.attach.logging=yes. That will create a file <pid>.log in the VM's working directory.
FYI @pdbain.
@M-Davies any chance to try -Dcom.ibm.tools.attach.logging=yes?
@JasonFengJ9 Just got to them this morning
PassingLinux.log
FailingWindows.log
Currently running another test with -Dcom.ibm.tools.attach.enable=no
Test failed with the same error as above. Running two more internal tests (one which should pass and one with -Dcom.ibm.tools.attach.enable=no, both with logs enabled)
EDIT: Tests perform as expected, the test certainly requires -Dcom.ibm.tools.attach.enable
Thanks @M-Davies, pls collect following info:
-Djdk.attach.allowAttachSelf=true in the command line;-Dcom.ibm.tools.attach.logging=yes, after the test, zip all files and subdirectories without modifying the file names;openjdk_x86-64_windows hyc-runtimes Jenkins build:Eclipse OpenJ9 VM AdoptOpenJDK (build master-5dd23af84, JRE 11 Windows Server 2012 R2 amd64-64-Bit Compressed References 20190810_300 (JIT enabled, AOT enabled)
OpenJ9 - 5dd23af84
OMR - 6e99760b
JCL - 965d0c0df3 based on jdk-11.0.4+11)
Which produces:
STDERR:
09:00:51 com.sun.tools.attach.AttachNotSupportedException: target not found
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.attachTargetImpl(OpenJ9VirtualMachine.java:151)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.lambda$attachTarget$1(OpenJ9VirtualMachine.java:129)
09:00:51 at com.ibm.tools.attach.attacher.OpenJ9VirtualMachine$$Lambda$28.000000009373A2A0.run(Unknown Source)
09:00:51 at java.base/java.security.AccessController.doPrivileged(AccessController.java:734)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.attachTarget(OpenJ9VirtualMachine.java:131)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9AttachProvider.attachVirtualMachine(OpenJ9AttachProvider.java:64)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9AttachProvider.attachVirtualMachine(OpenJ9AttachProvider.java:48)
09:00:51 at jdk.attach/com.sun.tools.attach.VirtualMachine.attach(VirtualMachine.java:207)
09:00:51 at GetPackageBootLoaderChildLayer.main(GetPackageBootLoaderChildLayer.java:45)
09:00:51 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:00:51 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
09:00:51 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:00:51 at java.base/java.lang.reflect.Method.invoke(Method.java:566)
09:00:51 at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:00:51 at java.base/java.lang.Thread.run(Thread.java:831)
09:00:51
09:00:51 JavaTest Message: Test threw exception: com.sun.tools.attach.AttachNotSupportedException: target not found
09:00:51 JavaTest Message: shutting down test
I couldn't replicate the error locally on Windows 10 so I'm leaning towards this being an infrastructure issue at this point.
Eclipse OpenJ9 VM AdoptOpenJDK (build master-81195db9c, JRE 11 Windows Server 2016 amd64-64-Bit Compressed References 20190812_302 (JIT enabled, AOT enabled)
08:57:29 OpenJ9 - 81195db9c
08:57:29 OMR - 6e99760b
08:57:29 JCL - 965d0c0df3 based on jdk-11.0.4+11)
The test also fails but with a different error:
08:58:10 Attempting to destroy all caches in cacheDir C:\Users\jenkins\AppData\Local\javasharedresources\
08:58:10
08:58:10 JVMSHRC806I Compressed references persistent shared cache "sharedcc_jenkins" has been destroyed. Use option -Xnocompressedrefs if you want to destroy a non-compressed references cache.
08:58:10 JVMSHRC241E Error: unable to delete shared class cache file
08:58:10 JVMSHRC336E Port layer error code = -100
08:58:10 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:10 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:10 JVMSHRC241E Error: unable to delete shared class cache file
08:58:10 JVMSHRC336E Port layer error code = -100
08:58:10 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:10 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:10
08:58:10 Attempting to destroy all caches in cacheDir C:\Users\jenkins\AppData\Local\javasharedresources\
08:58:10
08:58:10 JVMSHRC241E Error: unable to delete shared class cache file
08:58:10 JVMSHRC336E Port layer error code = -100
08:58:10 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:10 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:10 JVMSHRC241E Error: unable to delete shared class cache file
08:58:10 JVMSHRC336E Port layer error code = -100
08:58:10 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:10 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:10 cache cleanup done
08:58:10 variation: NoOptions
08:58:10 JVM_OPTIONS: -Xcompressedrefs
08:58:10 { itercnt=1; \
08:58:10 mkdir -p "C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests/\\TestConfig\\test_output_15658558851564\\jdk_custom_0"; \
08:58:10 cd "C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests/\\TestConfig\\test_output_15658558851564\\jdk_custom_0"; \
08:58:10 "C:/Users/jenkins/workspace/Grinder_Advanced/openjdkbinary/j2sdk-image\\bin\\java" -Xmx512m -jar "C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests///..//jvmtest\\openjdk\\jtreg\\lib\\jtreg.jar" \
08:58:10 -agentvm -a -ea -esa -v:fail,error,time,nopass -retain:fail,error,*.dmp,javacore.*,heapdump.*,*.trc -ignore:quiet -timeoutFactor:8 -xml:verify -concurrency:4 -vmoptions:"-Xmx512m -Xcompressedrefs " \
08:58:10 -w ""C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests/\\TestConfig\\test_output_15658558851564\\jdk_custom_0"\\work" \
08:58:10 -r "C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests///..//jvmtest\\openjdk\\report" \
08:58:10 -jdk:"C:/Users/jenkins/workspace/Grinder_Advanced/openjdkbinary/j2sdk-image" \
08:58:10 "C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests/\\openjdk\\openjdk-jdk\\test\\jdk\\java/lang/Class/GetPackageBootLoaderChildLayer.java"; \
08:58:10 if [ $? -eq 0 ] ; then echo ""; echo "jdk_custom_0""_PASSED"; echo ""; cd C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests/; else echo ""; echo "jdk_custom_0""_FAILED"; echo ""; fi; } 2>&1 | tee -a "C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests/\\TestConfig\\test_output_15658558851564\\TestTargetResult";
08:58:10 Error: Unable to access jarfile C:/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests///..//jvmtest\openjdk\jtreg\lib\jtreg.jar
08:58:10
08:58:10 jdk_custom_0_FAILED
08:58:10
08:58:10 "C:/Users/jenkins/workspace/Grinder_Advanced/openjdkbinary/j2sdk-image\\bin\\java" -Xshareclasses:destroyAll; "C:/Users/jenkins/workspace/Grinder_Advanced/openjdkbinary/j2sdk-image\\bin\\java" -Xshareclasses:groupAccess,destroyAll; echo "cache cleanup done";
08:58:11
08:58:11 Attempting to destroy all caches in cacheDir C:\Users\jenkins\AppData\Local\javasharedresources\
08:58:11
08:58:11 JVMSHRC241E Error: unable to delete shared class cache file
08:58:11 JVMSHRC336E Port layer error code = -100
08:58:11 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:11 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:11 JVMSHRC241E Error: unable to delete shared class cache file
08:58:11 JVMSHRC336E Port layer error code = -100
08:58:11 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:11 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:11
08:58:11 Attempting to destroy all caches in cacheDir C:\Users\jenkins\AppData\Local\javasharedresources\
08:58:11
08:58:11 JVMSHRC241E Error: unable to delete shared class cache file
08:58:11 JVMSHRC336E Port layer error code = -100
08:58:11 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:11 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:11 JVMSHRC241E Error: unable to delete shared class cache file
08:58:11 JVMSHRC336E Port layer error code = -100
08:58:11 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
08:58:11 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
08:58:11 cache cleanup done
08:58:11 jdk_custom_0 Finish Time: Thu Aug 15 00:58:08 2019 Epoch Time (ms): 1565855888722
08:58:11 make[1]: Leaving directory '/cygdrive/c/Users/jenkins/workspace/Grinder_Advanced/openjdk-tests/openjdk'
openjdk_test_output.tar.gzOnly on Windows, specifically to the openjdk_x86-64_windows hyc-runtimes Jenkins build.
I couldn't replicate the error locally on Windows 10.
Did the failure occur in a specific Jenkins machine?
Can those Windows machine be rebooted?
It seems to be a general problem. I ran the test 5 times, each on a different machine, all failing with the AttachNotSupportedException
Can we have machine access to grab the log files generated via -Dcom.ibm.tools.attach.logging=yes?
Failing: AdoptOpenJDK Jenkins build
Log file from it: 17676.log
Apparently the attacher thread started teardown before the target (itself) thread finishes the initialization hence it can't find the target at all.
Apparently the attacher thread started teardown before the target (itself) thread finishes the initialization hence it can't find the target at all.
This is normal behaviour: the attach API shuts down when the JVM terminates, i.e. all non-daemon threads exited. In the case of short-running applications, the initializer and teardown run concurrently.
According to the log, the test passed:
04:18:40 ACTION: main -- Passed. Execution successful
04:18:40 REASON: User specified action: run main/othervm --limit-modules jdk.attach -Djdk.attach.allowAttachSelf GetPackageBootLoaderChildLayer
04:18:40 TIME: 1.026 seconds
04:18:40 messages:
04:18:40 command: main --limit-modules jdk.attach -Djdk.attach.allowAttachSelf GetPackageBootLoaderChildLayer
04:18:40 reason: User specified action: run main/othervm --limit-modules jdk.attach -Djdk.attach.allowAttachSelf GetPackageBootLoaderChildLayer
04:18:40 Mode: othervm [/othervm specified]
04:18:40 Additional options from @modules: --add-modules jdk.attach
04:18:40 elapsed time (seconds): 1.026
04:18:40 configuration:
04:18:40 Boot Layer
04:18:40 add modules: jdk.attach
04:18:40 limit modules: jdk.attach
04:18:40
04:18:40 STDOUT:
04:18:40 STDERR:
04:18:40 STATUS:Passed.
but failed for other reasons:
04:18:40 -Dcom.ibm.tools.attach.logging=yes \
04:18:40 --limit-modules jdk.attach \
04:18:40 -Djdk.attach.allowAttachSelf \
04:18:40 com.sun.javatest.regtest.agent.MainWrapper 'C:\Users\jenkins\workspace\Grinder_Advanced\openjdk-tests\TestConfig\test_output_15659434632702\jdk_custom_0\work\java\lang\Class\GetPackageBootLoaderChildLayer.d\main.0.jta'
04:18:40
04:18:40 TEST RESULT: Error. failed to clean up files after test
04:18:40 --------------------------------------------------
04:18:40 Test results: error: 1
04:18:53 Report written to C:\Users\jenkins\workspace\Grinder_Advanced\jvmtest\openjdk\report\html\report.html
04:18:53 Results written to C:\Users\jenkins\workspace\Grinder_Advanced\openjdk-tests\TestConfig\test_output_15659434632702\jdk_custom_0\work
04:18:53 Error: Some tests failed or other problems occurred.
04:18:53
04:18:53 jdk_custom_0_FAILED
04:18:53
04:18:53 "C:/Users/jenkins/workspace/Grinder_Advanced/openjdkbinary/j2sdk-image\\bin\\java" -Xshareclasses:destroyAll; "C:/Users/jenkins/workspace/Grinder_Advanced/openjdkbinary/j2sdk-image\\bin\\java" -Xshareclasses:groupAccess,destroyAll; echo "cache cleanup done";
04:18:53
04:18:53 Attempting to destroy all caches in cacheDir C:\Users\jenkins\AppData\Local\javasharedresources\
04:18:53
04:18:53 JVMSHRC806I Compressed references persistent shared cache "sharedcc_jenkins" has been destroyed. Use option -Xnocompressedrefs if you want to destroy a non-compressed references cache.
04:18:53 JVMSHRC241E Error: unable to delete shared class cache file
04:18:53 JVMSHRC336E Port layer error code = -100
04:18:53 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
04:18:53 JVMSHRC429I Failed to remove older generation of shared class cache "sharedcc_jenkins"
Try running with shared classes disabled.
Results in similar error
JVMSHRC806I Compressed references persistent shared cache "sharedcc_jenkins" has been destroyed. Use option -Xnocompressedrefs if you want to destroy a non-compressed references cache.
14:23:54 JVMSHRC241E Error: unable to delete shared class cache file
14:23:54 JVMSHRC336E Port layer error code = -100
14:23:54 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
14:23:54 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
14:23:54 JVMSHRC241E Error: unable to delete shared class cache file
14:23:54 JVMSHRC336E Port layer error code = -100
14:23:54 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
14:23:54 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
14:23:54
14:23:54 Attempting to destroy all caches in cacheDir C:\Users\jenkins\AppData\Local\javasharedresources\
14:23:54
14:23:54 JVMSHRC241E Error: unable to delete shared class cache file
14:23:54 JVMSHRC336E Port layer error code = -100
14:23:54 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
14:23:54 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
14:23:54 JVMSHRC241E Error: unable to delete shared class cache file
14:23:54 JVMSHRC336E Port layer error code = -100
14:23:54 JVMSHRC337E Platform error message: (32) The process cannot access the file because it is being used by another process.
14:23:54 JVMSHRC430I Failed to remove current generation of shared class cache "sharedcc_jenkins"
@pdbain-ibm what's your view on following stacktrace?
STDERR:
09:00:51 com.sun.tools.attach.AttachNotSupportedException: target not found
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.attachTargetImpl(OpenJ9VirtualMachine.java:151)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.lambda$attachTarget$1(OpenJ9VirtualMachine.java:129)
09:00:51 at com.ibm.tools.attach.attacher.OpenJ9VirtualMachine$$Lambda$28.000000009373A2A0.run(Unknown Source)
09:00:51 at java.base/java.security.AccessController.doPrivileged(AccessController.java:734)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9VirtualMachine.attachTarget(OpenJ9VirtualMachine.java:131)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9AttachProvider.attachVirtualMachine(OpenJ9AttachProvider.java:64)
09:00:51 at jdk.attach/com.ibm.tools.attach.attacher.OpenJ9AttachProvider.attachVirtualMachine(OpenJ9AttachProvider.java:48)
09:00:51 at jdk.attach/com.sun.tools.attach.VirtualMachine.attach(VirtualMachine.java:207)
09:00:51 at GetPackageBootLoaderChildLayer.main(GetPackageBootLoaderChildLayer.java:45)
09:00:51 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:00:51 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
09:00:51 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:00:51 at java.base/java.lang.reflect.Method.invoke(Method.java:566)
09:00:51 at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:00:51 at java.base/java.lang.Thread.run(Thread.java:831)
09:00:51
09:00:51 JavaTest Message: Test threw exception: com.sun.tools.attach.AttachNotSupportedException: target not found
09:00:51 JavaTest Message: shutting down test
This clearly indicated that the target not found at VirtualMachine vm = VirtualMachine.attach(vmid); https://github.com/ibmruntimes/openj9-openjdk-jdk11/blob/965d0c0df359f3da224b865701bbcc044b7104c2/test/jdk/java/lang/Class/GetPackageBootLoaderChildLayer.java#L45
It appears https://ci.adoptopenjdk.net/view/Test_grinder/job/Grinder_Advanced/130/ didn't reproduce same failure reported in this issue.
Results in similar error
@M-Davies did the test run with -Xshareclasses:none?
@M-Davies did the test run with
-Xshareclasses:none?
Yes it did. The above is from ci.adoptopenjdk.net. The original AttachNotSupportedException is from hyc-runtimes
The above is from ci.adoptopenjdk.net. The original AttachNotSupportedException is from hyc-runtimes
Just to clarify, AttachNotSupportedException only occurred within internal jenkins build hyc-runtimes, is that correct?
If so, pls provide the link (or ping me in the slack).
I suggest open another issue to track the shareclass issue.
@JasonFengJ9 Correct. Pinged you with a currently running job
^^ Issue for the Adopt error
EDIT: I can't seem to replicate the error on Adopt again so I've closed the issue. Will keep an eye on it in case it pops back up. Hyc-runtimes is still failing
Reproduce the AttachNotSupportedException at an internal jenkins machine, it appears Attach API initializer thread attempted to create common directory in C:\Windows and failed.
printenv shows no defines for TMP, TEMP or USERPROFILE hence GetTempPathW falls back to the Windows directory.
This seems a machine configuration issue.
Setting environment variable TMP or TEMP fixes AttachNotSupportedException. Infra team is working on a proper script change.