JDK-8307467 : Release Note: Avoid JVM crash when containers share the same /tmp dir
  • Type: Sub-task
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 8u381
  • Priority: P4
  • Status: Resolved
  • Resolution: Withdrawn
  • Submitted: 2023-05-04
  • Updated: 2023-06-07
  • Resolved: 2023-06-06
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8
8-poolResolved
Description
Previous JDK releases assumed process IDs to be unique and used them for file naming that stores run-time generated data in /tmp folder. This may cause conflicts when multiple Java apps run in the container share /tmp directory on the host machine and try to create files with the same name.
Starting from this JDK release, the JVMs become aware of possible conflicts over the files in /tmp folder and allow only one of the competing JVMs (the winner) to write to the file.

The general advice then would be to not share /tmp folder across containers running JVMs.
The `-XX:-UsePerfData` command-line option can be used to prevent JVM from writing performance data to `/tmp/hsperfdata_$USER/<pid>` file.
Comments
The changes from the parent ticket were in particular aggregated in the Release note "umbrella" ticket JDK-8307635. Closing this one as a duplicate.
11-05-2023