jprofiler远程连接

1、客户端和服务端都需要安装jprofiler

2、客户端系统配置

vim /etc/profile

在末尾添加:

JPROFILER_HOME=/opt/jprofiler9/bin/linux-x64

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$JPROFILER_HOME

表示增加一个动态连接库目录

3、客户端java服务器起动参数,如tomcat

JAVA_OPTS="-agentpath:/opt/jprofiler9/bin/linux-x64/libjprofilerti.so=port=8849,nowait -server -Xms256m -Xmx640m -XX:PermSize=64M -XX:MaxPermSize=128m"

主要是:

-agentpath:/opt/jprofiler9/bin/linux-x64/libjprofilerti.so=port=8849,nowait 

表示给JVM启动时添加一个agent,用于监控和分析jvm运行情况

4、服务只需要连接创建一个新的远程连接

Integration Wizards --> New Remote Integration

按向导一步步设置

猜你喜欢

转载自piaoling.iteye.com/blog/2315594