hq监控tomcat 问题

classic 经典版 list 列表 threaded 结构树
3 条帖子 选项
回复 | 结构树
以树状图样式打开这个帖子
|

hq监控tomcat 问题

gralph
我这里遇到的问题和这个帖子的问题是一样的
http://hq.innovatedigital.com/hyperic-hq-tomcat-td27.html
按照官网的配置,打开jmx
http://support.hyperic.com/display/hyperforge/Apache+Tomcat+6.0+server
不起作用,还是按照tomcat官网的配置
http://tomcat.apache.org/tomcat-6.0-doc/monitoring.html.
jconsloe才能访问jmx

报错信息也和那帖子用户一样
1)This resource is turned off or has not been configured properly.
                          The problem is: Invalid configuration: Error reported by Agent @ 192.168.1.115:2144:                                        
                           java.lang.NullPointerException
                           Please turn on the server, or fix its Configuration Properties.
                    (2)The configuration has not been set for this resource due to : Agent error: Could not  
                            open
                            Windows Service: Apache Tomcat
我用的是start.bat启动的

这个在国外论坛上也有相同的提问,但是都没有回答
请问究竟如何配置,才能使得hq监控到tomcat的服务
或者这个是开源软件故意不回答,让用户花钱买服务


回复 | 结构树
以树状图样式打开这个帖子
|

Re: hq监控tomcat 问题

Martin King
管理员
Hyperic HQ 对 Tomcat 的监控做的还是很全面的,Springsource 和 hyperic 是一家的。
但是配置起来,与下面几个因素有关:
1,是windows 还是 非Windows,
2, 如果是windows,是服务方式启动还是 standalone方式。
配置方式不尽相同。

如果你的hypeic hq 能够自动发现tomcat,您就成功了一半。只需配置下文的 1 就应该可以了。

比较通用做法:
1 更改Tomcat启动脚本catalina.bat配置JMX监控,Tomcat 5.x,6.x,7.x类似。
可参考 http://tomcat.apache.org/tomcat-5.5-doc/monitoring.html
一个简单的无须JMX验证的快速配置只需要在catalina.bat中设置:(无折行)

JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote.port=6969 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false

如果您不能修改tomcat的启动参数,怎么办?有办法,但是需要HQ用户与TOmcat用户是同一个。然后jmx_url: ptql:process.query

如果Hyperic HQ没有自动发现Tomcat,需要在HQ手工增加TOmcat server。.....其中 service_name 可以设置为 Hyepric HQ Agent。WIndows,tomcat以standalone方式启动,HQ  将不能控制TOmcat.
回复 | 结构树
以树状图样式打开这个帖子
|

Could not map vmid to user Name? 如何解决

Martin King
管理员
Could not map vmid to user Name

The UID of a process is the user ID of the user causing its execution.
The GID of a process is the group ID of the user causing its execution.

Use the id command to find out your UID/GID.

JConsole requires to be run with the same UID/GID as the process to
be monitored in oder to be able to connect to it. But I don't think this is
the root cause of your problem.

Please post the output of the jps -mlv command?

If the output is empty please verify that you have readwrite access in the
directory /tmp/hsperfdata_<loginname> which is where the JVM stores
all the jvmstat information for a given java process.

IF the problem still persists have a look at the JConsole FAQ to see if you
can find the answer to your problem:

http://java.sun.com/javase/6/docs/technotes/guides/management/faq.html