Skip to main content

Cannot connect with jconsole

3 replies [Last post]
Joined: 2003-06-13

When using jdk 6.0 on remote linux box cannot connect with jconsole(nor from 6.0 or 5.0)
When use jdk 5.0 on the same box all ok
what i do wrong?
netstat reports established connection:
netstat -a|grep 15000
tcp 0 0 *:15000 *:* LISTEN
tcp 0 0 test:15000 ESTABLISHED

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2005-08-08

I started a managed application on Linux with mustang b69 and then started jconsole on another machine and it connected okay (both J2SE 5.0 and 6.0). Are you sure this is indeed working for you with 5.0?

As you mention Linux, it would be useful to know if the machines uses DHCP and to know what "hostname -i" prints. If it prints the loopback address that will explain it (but doesn't explain why it works with 5.0, if that it what you are saying). In that case you will need to fix your /etc/hosts file so that the hostname resolves to the actual host address. This issue is documented in the jconsole FAQ and arises with all RMI applications.

One other thing that would be useful to know is if you are using SSL.

Joined: 2003-06-13

Thanks for response

hostname -i reports
I fix that in /etc/hosts, restart app ... and it's working!!!!
Great thanks :)

Joined: 2005-02-19

That's a phenomenon I've often had with Linux installations. The J2SE ORB would put into IORs. Either the way Java determines the hostname or the Linux /etc/hosts are broken.