-
Enhancement
-
Resolution: Unresolved
-
P3
-
13
A common scenario where a Monitored VM runs inside a Docker container, while the observer tool/process is on a host system. The observer should be able to control JFR recording via JCMD (JFR.start/stop/check/dump).
Important notes:
-- jcmd -l (list) running outside of the container (on a host system) does not seem to work (investigation in progress)
-- use 'ps' command to discover the observed JVM process
-- in order for JCMD and attach (com.sun.tools.attach.VirtualMachine.attach) to work, the user ID of the monitored VM should match or be accessible by the user of the observer tool/process; for that, use the following:
- run "id" on the host system, record user ID of the 'test' user (aka observer)
- when starting docker, use --user=<UID> (E.g.: docker run --user=123456)
Important notes:
-- jcmd -l (list) running outside of the container (on a host system) does not seem to work (investigation in progress)
-- use 'ps' command to discover the observed JVM process
-- in order for JCMD and attach (com.sun.tools.attach.VirtualMachine.attach) to work, the user ID of the monitored VM should match or be accessible by the user of the observer tool/process; for that, use the following:
- run "id" on the host system, record user ID of the 'test' user (aka observer)
- when starting docker, use --user=<UID> (E.g.: docker run --user=123456)
- is blocked by
-
JDK-8228343 JCMD and attach fail to work across Linux Container boundary
-
- Resolved
-
- relates to
-
JDK-8193710 jcmd -l and jps commands do not list Java processes running in Docker containers
-
- Resolved
-
-
JDK-8195809 [TESTBUG] jps and jcmd -l support for containers is not tested
-
- Resolved
-
-
JDK-8221711 [TESTBUG] create more tests for JFR in container environment
-
- Resolved
-
-
JDK-8227122 [TESTBUG] Create Docker sidecar test cases
-
- Resolved
-