You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@karaf.apache.org by Mohammad Shamsi <m....@gmail.com> on 2015/09/09 12:01:10 UTC
JMX Remote connection with host 0.0.0.0
Hi,
I am using karaf 3.0.4 with karaf management (jmx) enabled.
When rmiRegistryHost is set to 0.0.0.0 ( default ), I am not able to
connect from remote machine. Only if I replace 0.0.0.0 with host IP
address, the remote JMX connection would be possible.
I was thinking that 0.0.0.0 binds the server to all interfaces, but
apparently that is not correct. Is this a bug or I am missing something ?
Cheers,
M. Sarbandian
Re: JMX Remote connection with host 0.0.0.0
Posted by mhshams <m....@gmail.com>.
The problem was related to this ticket:
https://issues.apache.org/jira/browse/KARAF-1138
I am using DHCP server and my etc/hosts contains only localhost entry which
confuses the RMI registry.
If I edit the hosts file with proper hostname and ip address, the connection
will be successful.
Thanks
--
View this message in context: http://karaf.922171.n3.nabble.com/JMX-Remote-connection-with-host-0-0-0-0-tp4042424p4042666.html
Sent from the Karaf - User mailing list archive at Nabble.com.
Re: JMX Remote connection with host 0.0.0.0
Posted by Mohammad Shamsi <m....@gmail.com>.
karaf machine is using IPV4.
I can see the machine is listening on given ports ( *:44444 and *:1099 )
I can even use telnet from remote machine on those ports successfully.
But jconsole is NOT able to connect and in order to make it work I need to
change "0.0.0.0" to the host IP in shell config file.
On Wed, 9 Sep 2015 at 15:46 Jean-Baptiste Onofré <jb...@nanthrax.net> wrote:
> Hi Mohammad,
>
> yes, it's a typo.
>
> Are you use IPv4 or v6 on your machine ?
>
> Regards
> JB
>
> On 09/09/2015 03:31 PM, Mohammad Shamsi wrote:
> > Hi JB,
> >
> > I am using this uri:
> > * service:jmx:rmi:///jndi/rmi://<my-host>:1099/karaf-root*
> >
> > btw, your example uri starts with: *service:rmi:jmx *instead
> > of* service:jmx:rmi . *is that a typo?
> >
> >
> > On Wed, 9 Sep 2015 at 15:21 Jean-Baptiste Onofré <jb@nanthrax.net
> > <ma...@nanthrax.net>> wrote:
> >
> > Hi Mohammed,
> >
> > What service URL do you use remotely ? You should use
> > service:rmi:jmx:///jndi/rmi://host:port/karaf-root
> >
> > I confirm that 0.0.0.0 binds to all network interfaces.
> >
> > Regards
> > JB
> >
> > On 09/09/2015 12:01 PM, Mohammad Shamsi wrote:
> > > Hi,
> > >
> > > I am using karaf 3.0.4 with karaf management (jmx) enabled.
> > > When rmiRegistryHost is set to 0.0.0.0 ( default ), I am not able
> to
> > > connect from remote machine. Only if I replace 0.0.0.0 with host
> IP
> > > address, the remote JMX connection would be possible.
> > >
> > > I was thinking that 0.0.0.0 binds the server to all interfaces,
> but
> > > apparently that is not correct. Is this a bug or I am missing
> > something ?
> > >
> > >
> > > Cheers,
> > > M. Sarbandian
> >
> > --
> > Jean-Baptiste Onofré
> > jbonofre@apache.org <ma...@apache.org>
> > http://blog.nanthrax.net
> > Talend - http://www.talend.com
> >
>
> --
> Jean-Baptiste Onofré
> jbonofre@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>
Re: JMX Remote connection with host 0.0.0.0
Posted by Jean-Baptiste Onofré <jb...@nanthrax.net>.
Hi Mohammad,
yes, it's a typo.
Are you use IPv4 or v6 on your machine ?
Regards
JB
On 09/09/2015 03:31 PM, Mohammad Shamsi wrote:
> Hi JB,
>
> I am using this uri:
> * service:jmx:rmi:///jndi/rmi://<my-host>:1099/karaf-root*
>
> btw, your example uri starts with: *service:rmi:jmx *instead
> of* service:jmx:rmi . *is that a typo?
>
>
> On Wed, 9 Sep 2015 at 15:21 Jean-Baptiste Onofré <jb@nanthrax.net
> <ma...@nanthrax.net>> wrote:
>
> Hi Mohammed,
>
> What service URL do you use remotely ? You should use
> service:rmi:jmx:///jndi/rmi://host:port/karaf-root
>
> I confirm that 0.0.0.0 binds to all network interfaces.
>
> Regards
> JB
>
> On 09/09/2015 12:01 PM, Mohammad Shamsi wrote:
> > Hi,
> >
> > I am using karaf 3.0.4 with karaf management (jmx) enabled.
> > When rmiRegistryHost is set to 0.0.0.0 ( default ), I am not able to
> > connect from remote machine. Only if I replace 0.0.0.0 with host IP
> > address, the remote JMX connection would be possible.
> >
> > I was thinking that 0.0.0.0 binds the server to all interfaces, but
> > apparently that is not correct. Is this a bug or I am missing
> something ?
> >
> >
> > Cheers,
> > M. Sarbandian
>
> --
> Jean-Baptiste Onofré
> jbonofre@apache.org <ma...@apache.org>
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>
--
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com
Re: JMX Remote connection with host 0.0.0.0
Posted by Mohammad Shamsi <m....@gmail.com>.
Hi JB,
I am using this uri:
* service:jmx:rmi:///jndi/rmi://<my-host>:1099/karaf-root*
btw, your example uri starts with: *service:rmi:jmx *instead of*
service:jmx:rmi
. *is that a typo?
On Wed, 9 Sep 2015 at 15:21 Jean-Baptiste Onofré <jb...@nanthrax.net> wrote:
> Hi Mohammed,
>
> What service URL do you use remotely ? You should use
> service:rmi:jmx:///jndi/rmi://host:port/karaf-root
>
> I confirm that 0.0.0.0 binds to all network interfaces.
>
> Regards
> JB
>
> On 09/09/2015 12:01 PM, Mohammad Shamsi wrote:
> > Hi,
> >
> > I am using karaf 3.0.4 with karaf management (jmx) enabled.
> > When rmiRegistryHost is set to 0.0.0.0 ( default ), I am not able to
> > connect from remote machine. Only if I replace 0.0.0.0 with host IP
> > address, the remote JMX connection would be possible.
> >
> > I was thinking that 0.0.0.0 binds the server to all interfaces, but
> > apparently that is not correct. Is this a bug or I am missing something ?
> >
> >
> > Cheers,
> > M. Sarbandian
>
> --
> Jean-Baptiste Onofré
> jbonofre@apache.org
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>
Re: JMX Remote connection with host 0.0.0.0
Posted by Jean-Baptiste Onofré <jb...@nanthrax.net>.
Hi Mohammed,
What service URL do you use remotely ? You should use
service:rmi:jmx:///jndi/rmi://host:port/karaf-root
I confirm that 0.0.0.0 binds to all network interfaces.
Regards
JB
On 09/09/2015 12:01 PM, Mohammad Shamsi wrote:
> Hi,
>
> I am using karaf 3.0.4 with karaf management (jmx) enabled.
> When rmiRegistryHost is set to 0.0.0.0 ( default ), I am not able to
> connect from remote machine. Only if I replace 0.0.0.0 with host IP
> address, the remote JMX connection would be possible.
>
> I was thinking that 0.0.0.0 binds the server to all interfaces, but
> apparently that is not correct. Is this a bug or I am missing something ?
>
>
> Cheers,
> M. Sarbandian
--
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com