"how does tools like JPS, JConsole or VisualVM know the JVMs running in a system? They simply look in the folder /tmp/hsperfdata_foo where a 32KB data file with the PID as name is created for each JVM."
Not a hidden feature of Java, but of Sun's (Oracle) JVM which I'm not sure if happens in other JVMs but it's kind of useful for doing different stuff.
"how does tools like JPS, JConsole or VisualVM know the JVMs running in a system? They simply look in the folder /tmp/hsperfdata_foo where a 32KB data file with the PID as name is created for each JVM."
Not a hidden feature of Java, but of Sun's (Oracle) JVM which I'm not sure if happens in other JVMs but it's kind of useful for doing different stuff.