On Tue, 30 Jan 2024 10:47:22 GMT, Sebastian Lövdahl <d...@openjdk.org> wrote:

> 8307977: jcmd and jstack broken for target processes running with elevated 
> capabilities

Hi, 
Yes makes sense, this seems like an oversight that we were not consistent with 
the path.

Does CAP_NET_BIND_SERVICE cause any issues for createAttachFile(int pid, int 
ns_pid) where it creates the .attach file in the current directory - it starts 
by trying "/proc/" + pid + "/cwd/" + ".attach_pid" + ns_pid, regardless of 
ns_pid.

I'm curious if that always fails in the situation that causes the issue in this 
bug.
If so looks like it would catch an IOException and then use 
findTargetProcessTmpDirectory, but wonder if we should predict it go straight 
there.

Thanks!

-------------

PR Comment: https://git.openjdk.org/jdk/pull/17628#issuecomment-1930386568

Reply via email to