服务器linux+tomcat,本机windows,简单记录一下Jprofiler remote的使用方法
1、服务端安装jprofiler
chmod +x jprofiler_linux_8_0_2.sh ./jprofiler_linux_8_0_2.sh -c
2、客户端配置
Integration type: [Generic application] Selected JVM: Oracle 1.6.0 (hotspot) Startup mode: Startup immediately, connect later with the JProfiler GUI (1) Please insert -agentpath:/home/admin/jprofiler8/bin/linux-x64/libjprofilerti.so=port=8849,nowait into the start command of your remote application right after the java command. A remote session named Remote application on 10.235.144.94 will be created that connects to a running instance of the remote application that is started with the modified start command.
有3种启动模式,可以通过名字看出有什么区别的,nowait是服务器正常启动,不需要等待jprofiler连接。而下面这种模式,则一直等待jprofiler的连接。。(等到花儿也谢了)
Integration type: [Generic application] Selected JVM: Oracle 1.6.0 (hotspot) Startup mode: Wait for a connection from the JProfiler GUI (1) Please insert -agentpath:/home/admin/jprofiler8/bin/linux-x64/libjprofilerti.so=port=8849 into the start command of your remote application right after the java command. A remote session named Remote application on 10.235.144.94 will be created that connects to a running instance of the remote application that is started with the modified start command.
3、服务端配置,根据上面的提示信息,在java启动参数行加上,如:
JAVA_OPTS="$JAVA_OPTS -agentpath:/home/admin/jprofiler8/bin/linux-x64/libjprofilerti.so=port=8849,nowait" export JAVA_OPTS
4、启动tomcat时,如果是“wait for...”模式,则会出现下方的提示信息,赶紧连吧
JProfiler> Protocol version 38 JProfiler> Using JVMTI JProfiler> JVMTI version 1.1 detected. JProfiler> 64-bit library JProfiler> Listening on port: 8849. JProfiler> Instrumenting native methods. JProfiler> Can retransform classes. JProfiler> Can retransform any class. JProfiler> Native library initialized JProfiler> VM initialized JProfiler> Waiting for a connection from the JProfiler GUI ...
如果是“no wait”模式,则不会有任何提示,服务器启动时即可用jprofiler连接,连接时会出现以下信息:
JProfiler> Using dynamic instrumentation JProfiler> Time measurement: elapsed time JProfiler> CPU profiling enabled JProfiler> Updating configuration. JProfiler> Retransforming 5698 class files.
参考
http://www.cnblogs.com/jayzee/p/3184087.html
http://www.blogjava.net/anymobile/articles/28248.html
相关推荐
jvisualvm 是一个功能强大且功能丰富的 Java 监控和 profiling 工具,它可以远程访问和监控 Java 应用程序,包括 Tomcat 应用服务器。下面将详细介绍如何使用 jvisualvm 远程访问 Linux 环境中的 Tomcat。 jdk 的...
不懂运行,下载完可以私聊问,可远程教学 该资源内项目源码是个人的毕设,代码都测试ok,都是运行成功后才上传资源,答辩评审平均分达到96分,放心下载使用! <项目介绍> 1、该资源内项目代码都经过测试运行成功,...
1. 使用远程调试:当设备无法直接连接到开发机时,可以通过网络进行远程调试,这需要配置设备和调试器的网络连接。 2. 日志记录:在代码中添加日志输出,可以帮助分析程序运行过程,特别是对于难以复现的问题,日志...
11. **Remote Profiling**:允许远程连接到正在运行的应用程序进行实时分析,无需重新启动。 使用YourKit Java Profiler,开发者可以进行深入的性能调试,找出代码中的性能瓶颈,从而提升应用程序的整体性能。同时...
4. **本地监测**: 选择"Local",表示你要监测的是本机上的Tomcat。 5. **选择启动类型**: 选择适合你的Tomcat启动方式,如"Start with profiling"或"Attach to running process"。 6. **定位Tomcat**: 指定Tomcat的...
该标题与描述明确指出本文档涉及的产品是一种能够提供高度精确的时间与频率信号的设备。在现代社会,尤其是在电信、航空航天、科学研究等领域,对于时间同步及频率稳定性的需求日益增加。因此,高精度的时间频率生成...
这意味着开发者可以远程连接到正在运行的Java应用,并对其进行性能分析而无需重启或者修改源代码。这种灵活性对于生产环境的性能调优尤其有价值,因为它允许开发者在不影响服务正常运行的情况下进行诊断。 此外,...
Atlassian-xmlrpc-binder-0.9.jar.zip 是一个包含了Atlassian公司开发的XML-RPC(远程过程调用)绑定器库的压缩文件,版本为0.9。这个库主要用于支持Atlassian产品与基于XML-RPC协议的服务进行交互,它简化了Java...
:skull_and_crossbones: 该项目不再维护。 我们强烈建议您切换到 ,以提供更好的性能和可用性...安装通过PyPI安装最新版本: $ pip install profiling剖析要分析单个程序,只需运行profiling命令: $ profiling your-pr
Atlassian-xmlrpc-binder-support-0.9.jar.zip 是一个针对Atlassian产品的特定版本的库,主要用于支持XML-RPC(远程过程调用)协议。XML-RPC是一种简单、轻量级的远程调用方法,它允许不同编程语言之间的互操作性,...
6. **远程连接**:Visual VM不仅支持本地应用监控,还可以连接到远程运行的Java应用,这对于分布式系统和云环境的调试十分有用。 7. **类和方法分析**:你可以查看类的加载情况,以及方法的调用频率和耗时,这有助...
3. 配置Xdebug的特定设置,如启用profiling(`xdebug.profiler_enable=1`)和远程调试(`xdebug.remote_enable=1`)。 4. 重启PHP服务器以应用更改。 通过Xdebug的profiling功能,开发者可以在每次请求后生成一个`....
5. **许可证信息**:在压缩包中,我们找到了atlassian-profiling-license.txt文件,这通常是Atlassian产品的许可协议,详细规定了使用、分发和修改该库的法律条款。在使用该库时,开发者必须遵守其中的规定,尊重...
7. **远程连接(Remote Profiling)**:除了本地应用,JProfiler还支持远程连接到其他服务器上的JVM,方便在分布式环境中进行性能调试。 8. **会话管理(Session Management)**:用户可以保存和加载分析会话,便于...
开发者可以在主机上运行GDB,连接到目标机上的VxWorks实例,进行调试操作。这对于没有图形界面或者远程开发的情况非常有用。 3. **Kernel Debugging** VxWorks内核调试是理解系统行为的关键。通过内核调试,可以...
- **Remote Profiling(远程性能分析)**:支持在不同机器上分析远程 JVM 的性能。 - **Behind the Scenes(幕后原理)**:详细介绍 jProfiler 如何采集数据及其内部工作原理。 **2. Configuration(配置)** -...
性能分析(Profiling)是Nsight工具中的另一个核心特性,它允许开发者分析CUDA应用程序的性能。性能分析的结果可以用于识别性能瓶颈,进而优化CUDA程序的运行效率。 更多关于Nsight的信息可以在NVIDIA的官方网站...
为了验证索引的效果,可以插入大量数据后,通过`SET PROFILING=1;`开启查询性能检测,然后执行SQL查询,比较有无索引时的执行时间。 用户管理是数据库安全的重要方面。在MySQL中,首先切换到`mysql`数据库,使用`...