You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by "dario.pezzi" <da...@gmail.com> on 2015/09/02 09:40:18 UTC

jolokia osgi - multiple instances

I have on the same windowsXP computer different instances of servicemix.

I installed jolokia on two instances following Gert Vanthienen's info
(http://servicemix.396122.n5.nabble.com/programmatically-get-server-load-information-from-Apache-ServiceMix-using-JMX-td5716769.html)
to activate a bridge to jmx.

On the two instances the osgi is active but I can connect only to 1
instances from my browser () to have jmx metrics.
This address http://192.168.100.4:8181/jolokia/ connect only to the first
instances.
Result:
{"timestamp":1441179598,"status":200,"request":{"type":"version"},"value":{"protocol":"7.0","agent":"1.1.1","info":{"product":"felix","vendor":"Apache","version":"3.0.9.fuse-03-11"}}}

How can I browse metric of the second instances? Do I need to change default
port?
Keep in mind that I didn't change anythink on the default jolokia conf.

If I need to change default port can you write some info.

Thanks, Dario 




--
View this message in context: http://servicemix.396122.n5.nabble.com/jolokia-osgi-multiple-instances-tp5722924.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Re: jolokia osgi - multiple instances

Posted by Achim Nierbeck <bc...@googlemail.com>.
this isn't related to jolokia, jolokia is just a servlet, so you actually
are having two servers with two embedded web-containers running.
Therefore make sure one of your servers uses another port.
You'll find that in the org.ops4j.pax.web.cfg in the etc folder. There make
sure to set the following to a port available:
org.osgi.service.http.port

regards, Achim


2015-09-02 9:40 GMT+02:00 dario.pezzi <da...@gmail.com>:

> I have on the same windowsXP computer different instances of servicemix.
>
> I installed jolokia on two instances following Gert Vanthienen's info
> (
> http://servicemix.396122.n5.nabble.com/programmatically-get-server-load-information-from-Apache-ServiceMix-using-JMX-td5716769.html
> )
> to activate a bridge to jmx.
>
> On the two instances the osgi is active but I can connect only to 1
> instances from my browser () to have jmx metrics.
> This address http://192.168.100.4:8181/jolokia/ connect only to the first
> instances.
> Result:
>
> {"timestamp":1441179598,"status":200,"request":{"type":"version"},"value":{"protocol":"7.0","agent":"1.1.1","info":{"product":"felix","vendor":"Apache","version":"3.0.9.fuse-03-11"}}}
>
> How can I browse metric of the second instances? Do I need to change
> default
> port?
> Keep in mind that I didn't change anythink on the default jolokia conf.
>
> If I need to change default port can you write some info.
>
> Thanks, Dario
>
>
>
>
> --
> View this message in context:
> http://servicemix.396122.n5.nabble.com/jolokia-osgi-multiple-instances-tp5722924.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>



-- 

Apache Member
Apache Karaf <http://karaf.apache.org/> Committer & PMC
OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer &
Project Lead
blog <http://notizblog.nierbeck.de/>
Co-Author of Apache Karaf Cookbook <http://bit.ly/1ps9rkS>

Software Architect / Project Manager / Scrum Master

Re: jolokia osgi - multiple instances

Posted by Achim Nierbeck <bc...@googlemail.com>.
Again,

as already stated, neither hawtio nor jolokia are taking care of the
webcontainer port.
That's what Pax Web is for, it's a http-Service and therfore make sure you
configure this
service appropriately. In your case make sure to set the

org.osgi.service.http.port to another port than 8181, cause that one is
already used by your first instance running.

by the way you should see execptions in your log for servers 2 to 4 because
of "Port already in use".

regards, Achim


2015-09-02 17:44 GMT+02:00 dario.pezzi <da...@gmail.com>:

> Thanks for your responses.
>
> All instances (4 instances) have hawtio 1.4.4 installed in servicemix.
> I thought that installing hawtio in Karaf would automatically installed
> Jolokia too, but I did not see the package.
>
> Now I found that jolokia actually is installed and I can query
> via:http://192.168.100.4:8181/hawtio/jolokia
>
> So I change my original question.
> http://192.168.100.4:8181/hawtio/jolokia is working fr instances 1.
> How can I find the port is using hawtio for the other 3 instances?
>
> In this way I don't need to install jolokia agent again.
>
>
> Regards, Dario
>
>
>
>
>
>
> --
> View this message in context:
> http://servicemix.396122.n5.nabble.com/jolokia-osgi-multiple-instances-tp5722924p5722926.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>



-- 

Apache Member
Apache Karaf <http://karaf.apache.org/> Committer & PMC
OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer &
Project Lead
blog <http://notizblog.nierbeck.de/>
Co-Author of Apache Karaf Cookbook <http://bit.ly/1ps9rkS>

Software Architect / Project Manager / Scrum Master

Re: jolokia osgi - multiple instances

Posted by "dario.pezzi" <da...@gmail.com>.
Thanks for your responses.

All instances (4 instances) have hawtio 1.4.4 installed in servicemix.
I thought that installing hawtio in Karaf would automatically installed
Jolokia too, but I did not see the package.

Now I found that jolokia actually is installed and I can query
via:http://192.168.100.4:8181/hawtio/jolokia

So I change my original question.
http://192.168.100.4:8181/hawtio/jolokia is working fr instances 1.
How can I find the port is using hawtio for the other 3 instances?

In this way I don't need to install jolokia agent again.


Regards, Dario






--
View this message in context: http://servicemix.396122.n5.nabble.com/jolokia-osgi-multiple-instances-tp5722924p5722926.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.