title: Java VisualVM Remotely
body: <p>I have used this (<a href="https://stackoverflow.com/a/17457394/3009344">https://stackoverflow.com/a/17457394/3009344</a>) solution to remotely look into my Java VM.</p>
  
  <p>I am trying it with JConsole:</p>
  
  <ol>
  <li><p>Opening it</p></li>
  <li><p>Setting <code>service:jmx:rmi:///jndi/rmi://localhost:1100/jmxrmi</code> as remote process and connecting</p></li>
  </ol>
  
  <p>It works great, i can see many useful infos. What i really need, is to see when which thread is alive, just like in VisualVM.</p>
  
  <p>So i am running it, clicking File > Add JMX Connection. As Connection i am setting <code>service:jmx:rmi:///jndi/rmi://localhost:1100/jmxrmi</code> and then clicking OK.
  I can see in Overview correct Virtual Machine arguments and System Properties, also monitor and Threads are showing data.</p>
  
  <p>Suddenly after few seconds of happiness, i am losing SSH connection (Putty Fatal Error "Software caused connection abort", after reconnecting my PC cannot find such host :O), CPU and Memory sampling are showing as Not available.
  CPU Sampling is also showing me exact error (<a href="http://pastebin.com/A2wTjLQL" rel="nofollow noreferrer">http://pastebin.com/A2wTjLQL</a>).</p>
  
  <p>So i am trying to figure out, why is it happening. On JConsole everything is working fine.</p>