--- old/src/jdk.attach/solaris/classes/sun/tools/attach/VirtualMachineImpl.java 2018-10-02 07:47:21.192047924 -0400 +++ new/src/jdk.attach/solaris/classes/sun/tools/attach/VirtualMachineImpl.java 2018-10-02 07:47:20.780023854 -0400 @@ -212,7 +212,17 @@ // The door is attached to .java_pid in the temporary directory. private int openDoor(int pid) throws IOException { socket_path = tmpdir + "/.java_pid" + pid; - fd = open(socket_path); + try { + fd = open(socket_path); + } catch (IOException ioe) { + // Retry the operation after a short pause + try { + Thread.sleep(100); + fd = open(socket_path); + } catch (InterruptedException ie) { + // ignored + } + } // Check that the file owner/permission to avoid attaching to // bogus process