-1

I am trying to get hawtio on an ActiveMQ 5.11 server via the http://<host>:8161/api/jolokia URL. The URL works if I curl/hit it from a browser but when trying to use the hawtio.jar via java -jar hawtio.jar it fails.

It's working find on my development instance. The debug output says the following:

[qtp400507874-19] WARN org.eclipse.jetty.servlet.ServletHandler - 
/hawtio/proxy/http://192.168.1.171:8161/api/jolokia/
java.lang.SecurityException: Authentication Failed on remote server
http://192.168.1.171:8161/api/jolokia/?maxDepth=7&maxCollectionSize=500&ignoreErrors=true&canonicalNaming=false

Any suggestions on how to troubleshoot this? The only difference I can find is that the test box is on my local network (but not localhost) and the prod box is in AWS, but if it's communicating via port 8161 then that shouldn't matter.

dawud
  • 15,096
  • 3
  • 42
  • 61
TheFiddlerWins
  • 2,999
  • 1
  • 15
  • 22

2 Answers2

0

The problem I had was not with getting hawtio working itself (as I said, it's working find in my dev environment) but getting authenticated. I knew what I needed to do (enable RMI) but not how to do it and it's difficult since there are a couple of ways to do it and depending on distro etc they differ.

If anyone else is searching on this the trick was to get the following (the way my MQ is installed it's in the "env" file under the bin directory.

ACTIVEMQ_SUNJMX_CONTROL="--jmxurl service:jmx:rmi:///jndi/rmi://127.0.0.1:1099/jmxrmi --jmxuser controlRole --jmxpassword abcd1234"
TheFiddlerWins
  • 2,999
  • 1
  • 15
  • 22
0

I was able to login to activemq console, but not in hawtio.

In my case I found that:

  • activemq console credentials are read from conf/jetty-realm.properties
  • hawtio credentials are read from conf/users.properties and conf/groups.properties

In users.properties the password cannot contain same characters, in my case the euro sign €