JVM MCP 服务器
基于 Arthas 的 JVM 监控 MCP 服务器实现,提供简单易用的 Python 接口用于监控和分析 Java 进程。
特征
Arthas 工具的自动下载和管理
支持本地和远程Java进程监控
Java进程列表查询
实时JVM线程信息
JVM内存使用情况监控
线程堆栈跟踪信息
类加载信息查询
支持类和方法反编译
方法调用监控
动态日志级别调整
AI驱动的JVM性能分析
系统要求
Python 3.10+
Java 运行时环境 (JRE) 8+
网络连接(用于下载 Arthas)
SSH 访问目标服务器(如果使用远程模式)
安装和环境设置
1.安装uv工具
2.克隆项目
3. 使用 uv 初始化项目环境
4.配置环境变量(可选,用于远程连接)
创建.env文件,添加以下配置:
快速入门
使用 uv 启动服务器:
在 Python 代码中使用:
使用 MCP 工具:
使用配置文件:
如果不使用配置文件,它将读取系统环境变量,如果不存在,它将监视本地线程:
可用工具
重要提示
确保运行环境中安装了 Java
首次运行时会自动下载Arthas工具(arthas会下载到主目录,可以提前下载并命名为arthas-boot.jar)
需要目标 Java 进程的访问权限
远程模式需要 SSH 访问和适当的用户权限
建议在开发环境中使用,生产使用应仔细评估
反馈
如果您遇到任何问题,请提交问题或拉取请求。
执照
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
Tools
基于 Arthas 的 JVM 监控和控制平台服务器,提供用于监控和分析 Java 进程的 Python 接口,具有线程分析、内存监控和性能诊断功能。
Related Resources
Related MCP Servers
- -security-license-qualityA Python-based server allowing seamless integration with JIRA for managing and interacting with projects through custom APIs.Last updated -4Apache 2.0
- Asecurity-licenseAqualityA lightweight server that provides real-time system information including CPU, memory, disk, and GPU statistics for monitoring and diagnostic purposes.Last updated -1MIT License
- Asecurity-licenseAqualityA server monitoring and inspection tool collection that provides remote utilities for checking network interfaces, service statuses, and firewall configurations on servers.Last updated -1937MIT License
- -security-license-qualityAn advanced system monitoring solution that uses unsupervised machine learning algorithms to detect abnormal resource usage patterns in real-time, with features including anomaly detection, process analysis, and Discord integration.Last updated -1