Jprofiler的安装配置
JProfiler 是一个用于 java 系统监控分析的软件,功能很强大
它可以监控普通的 java application, application server 等
除了可以监控本地的程序,还可以对远程服务器上跑的应用进行监控
如果需要对远程服务器上的webserver进行监控,需要下载windows版本和linux版本
- 下载jprofiler_windows_6_0_3.zip,解压后,直接运行bin/jprofiler.exe即可开始安装
- 下载jprofiler_linux_6_0_3.sh,执行:
- chmod a+x jprofiler_linux_6_0_3.sh
- ./jprofiler_linux_6_0_3.sh
- vi /etc/profile
- export LD_LIBRARY_PATH=/opt/jprofiler6/bin/linux-x86:$LD_LIBRARY_PATH
- 在webserver中配置jprofiler,加入以下内容:对于Resin2.x和Resin3.0,将以上内容配置在resin/bin/wrapper.pl中的$JAVA_ARGS中,对于Resin3.1.x,则配置在resin.conf中 的<jvm-arg>中即可
折叠复制代码
折叠复制代码
- -agentpath:/opt/jprofiler6/bin/linux-x86/libjprofilerti.so=port=8849
4. 在windows上启动jprofiler,新建一个remote application session,一步一步的走下去
注意:如果新建session的时候,采用的是默认的wait for a conectin from the JProfiler GUI,那么在resin 里配置好Jprofiler后,resin的进程并不会马上启动,只有当Jprofiler的客户端连接上8849端口后,resin才会真正的启动