The reason VisualVM cannot find Java because of OS process privileges.
If you start VisualVM with the same user & security context as Java app you will see it: VisualVM will gain access to sockets, /proc
fs, etc...
To workaround the OS security stuff you can expose your Java app via JMX appending sys props:
-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.authenticate=false
-Dcom.sun.management.jmxremote.port=[...PORT...]
-Dcom.sun.management.jmxremote.ssl=false
-Djava.rmi.server.hostname=localhost
java.rmi.server.hostname
is an important security measure to prevent connection to your app JMX from outside. If you need a remote connection just pass the port with SSH tunnel.