Arthas MCP Proxy
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Arthas MCP ProxySSH to 192.168.1.100, list Java processes and thread dump for PID 1234"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Arthas MCP Proxy
An Arthas diagnostic proxy server based on MCP (Model Context Protocol), supporting dynamic SSH connections to any server for real-time JVM diagnostics within Claude conversations.
Features
Dynamic In-Conversation Connection: Directly pass SSH address, username, and password/key to connect to target servers in real-time.
Multi-Process Parallel Diagnostics: Each JVM process has an independent Arthas agent, allowing zero-latency switching between PIDs.
Automatic Connection Pooling: Caches SSH connections by
user@host:port, with automatic reclamation after 5 minutes of inactivity.Automatic Arthas Attach: Automatically attaches in the background upon the first use of a target PID, with subsequent reuse.
SSE Remote Deployment: Supports persistent deployment in HTTP SSE mode, allowing Claude to connect via URL.
Offline Build Support: Enables Docker builds in air-gapped environments via pre-downloaded whl packages.
Related MCP server: javaperf
MCP Tools List
Tool Name | Description |
| Establishes an SSH connection and returns a session_id |
| Lists Java processes on the target machine (shows Arthas attach status) |
| Gets thread stacks (top N by CPU) |
| Views memory/Dashboard information |
| Watches method input parameters and return values |
| Executes any Arthas command |
| Disconnects SSH and releases resources |
Concurrent Diagnostic Model
Important: Each JVM process requires an independent Arthas agent instance
PID 1234 (web) <---> Arthas agent (port 3658)
PID 5678 (cpu) <---> Arthas agent (port 3660)
PID 9012 (memory) <---> Arthas agent (port 3661)First Use: Automatic background attach, Arthas automatically assigns a port (approx. 5 seconds).
Subsequent Switching: Directly connects to an existing agent with zero latency.
Multi-Process Support: Can keep multiple agents running simultaneously and switch between them at will.
Resource Usage: Each agent consumes approximately 20-30MB of memory; it is recommended to keep the count <= 10 simultaneously.
Release: Automatically cleans up when executing
stopviaexec_commandor when disconnecting SSH.
Tech Stack
Component | Selection |
Language | Python 3.11+ |
MCP SDK | mcp >= 1.6.0 |
SSH Library | paramiko >= 3.4.0 |
HTTP Framework | starlette + uvicorn |
Quick Start
1. Online Build (Networked Environment)
docker build -t arthas-mcp-proxy .
# 或
docker-compose up -d2. Offline Build (Air-gapped Environment)
Step 1: Pre-download dependencies on a machine with internet access
bash download-packages.sh
# 完成后 packages/ 目录包含所有 .whl 文件Step 2: Package and transfer to the internal network
zip -r arthas-mcp-proxy.zip arthas-mcp-proxy/
# 通过 U 盘/SCP 传入内网服务器Step 3: Build in the internal network
cd arthas-mcp-proxy
docker build --build-arg PIP_SOURCE=offline -t arthas-mcp-proxy .
# 或
PIP_SOURCE=offline docker-compose up -d --build3. Claude Configuration
SSE Mode (Remote Deployment):
{
"mcpServers": {
"arthas": {
"type": "sse",
"url": "http://your-server-ip:8000/sse"
}
}
}stdio Mode (Local Embedding):
{
"mcpServers": {
"arthas": {
"command": "python",
"args": ["/path/to/main.py", "--transport", "stdio"]
}
}
}Usage Example
In a Claude conversation:
连接到 192.168.1.100,用户 root,密码 xxx,查看上面的 Java 进程。Claude will automatically call connect_ssh -> list_java_processes.
Then:
查看 PID 1234 的线程栈 top 10,然后查看 PID 5678 的内存情况。Claude will automatically switch diagnostics between multiple PIDs, attaching automatically upon the first use of each PID and reusing it thereafter.
Project Structure
arthas-mcp-proxy/
├── main.py # MCP Server 入口(SSE + stdio 双模式)
├── ssh_pool.py # SSH 连接池(动态连接 + session 复用)
├── arthas_client.py # Arthas 命令封装(多 PID 并行支持)
├── requirements.txt # Python 依赖
├── Dockerfile # 双模式构建 Dockerfile
├── docker-compose.yml # Docker Compose 配置
├── download-packages.sh # 外网预下载脚本
├── packages/ # 离线 whl 包目录
└── README.md # 本文档Target Machine Requirements
Arthas installed (
/opt/arthas/as.shor custom path)SSH accessible, with the running user having permissions to attach to the target JVM
jpscommand available (included with JDK)
License
MIT License
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceJava diagnostics MCP server for LLM integration with Alibaba Arthas, enabling analysis and diagnosis of Java applications.56MIT
- AlicenseAqualityDmaintenanceMCP server for profiling Java applications via JDK utilities (jcmd, jfr, jps). Enables AI assistants to diagnose performance, analyze threads, and inspect JFR recordings without manual CLI usage.268010MIT
- AlicenseNot gradedqualityCmaintenanceA lightweight, zero-agent SSH operations tool that enables remote command execution, file transfer, and audit logging. It integrates as an MCP server for AI-driven infrastructure management.26MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI tools to manage SSH connections, execute commands, transfer files, and perform remote server diagnostics via MCP protocol.13MIT
Related MCP Connectors
A MCP server built for developers enabling Git based project management with project and personal…
MCP Server for JFrog, providing tools for development and artifact management.
Scans MCP servers for tool poisoning, prompt injection and supply chain risks.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/narcissux/arthas-mcp-proxy'
If you have feedback or need assistance with the MCP directory API, please join our Discord server