title: JConsole over ssh local port forwarding
body: <p>I'd like to be able to remotely connect to a Java service that has JMX exposed, however it is blocked by a firewall.  I have tried to use ssh local port forwarding, however the connection fails.  Looking at wireshark, it appears that when you try to connect with jconsole, it wants to connect via some ephemeral ports after connecting to port 9999, which are blocked by the firewall.</p>
  
  <p>Is there any way to make jconsole only connect through 9999 or use a proxy?  Is <a href="https://web.archive.org/web/20150202095729/https://blogs.oracle.com/jmxetc/entry/connecting_through_firewall_using_jmx" rel="noreferrer">this article still the best solution</a>?  Or, am I missing something?</p>