pcp-mcp
MCP server for Performance Co-Pilot (PCP) metrics.
Query system performance metrics via the Model Context Protocol - CPU, memory, disk I/O, network, processes, and more.
📖 Full Documentation | 🚀 Getting Started
🚀 Quick Start (No Install)
Run immediately with uvx — no installation required:
uvx pcp-mcp
Or install as a persistent global tool:
uvx tool install pcp-mcp
pcp-mcp
📦 Installation
pip install pcp-mcp
Or with uv:
uv add pcp-mcp
📋 Requirements
- Python: 3.10+
- PCP: Performance Co-Pilot with
pmcdandpmproxyrunning# Fedora/RHEL/CentOS sudo dnf install pcp sudo systemctl enable --now pmcd pmproxy # Ubuntu/Debian sudo apt install pcp sudo systemctl enable --now pmcd pmproxy
⚙️ Configuration
Configure via environment variables:
| Variable | Description | Default |
|---|---|---|
PCP_HOST |
pmproxy host | localhost |
PCP_PORT |
pmproxy port | 44322 |
PCP_TARGET_HOST |
Target pmcd host to monitor | localhost |
PCP_USE_TLS |
Use HTTPS for pmproxy | false |
PCP_TLS_VERIFY |
Verify TLS certificates | true |
PCP_TLS_CA_BUNDLE |
Path to custom CA bundle | (optional) |
PCP_TIMEOUT |
Request timeout (seconds) | 30 |
PCP_USERNAME |
HTTP basic auth user | (optional) |
PCP_PASSWORD |
HTTP basic auth password | (optional) |
PCP_ALLOWED_HOSTS |
Hostspecs allowed via host param | (optional) |
🎯 Usage
Monitor localhost (default)
pcp-mcp
Monitor a remote host
PCP_TARGET_HOST=webserver1.example.com pcp-mcp
Or use the CLI flag:
pcp-mcp --target-host webserver1.example.com
Connect to remote pmproxy
PCP_HOST=metrics.example.com pcp-mcp
Use SSE transport
pcp-mcp --transport sse
🔌 MCP Client Configuration
Claude Desktop
Add to ~/.config/claude/claude_desktop_config.json:
{
"mcpServers": {
"pcp": {
"command": "uvx",
"args": ["pcp-mcp"]
}
}
}
For remote monitoring:
{
"mcpServers": {
"pcp": {
"command": "uvx",
"args": ["pcp-mcp", "--target-host", "webserver1.example.com"]
}
}
}
💡 Using
uvxmeans you don't need pcp-mcp installed — it runs directly from PyPI.
🛠️ Available Tools
System Monitoring
get_system_snapshot- Point-in-time system overview (CPU, memory, disk, network, load)get_process_top- Top processes by CPU, memory, or I/O usagequery_metrics- Fetch current values for specific PCP metricssearch_metrics- Discover available metrics by name patterndescribe_metric- Get detailed metadata about a metric
Example Queries
"What's the current CPU usage?"
→ Uses get_system_snapshot
"Show me the top 10 processes by memory usage"
→ Uses get_process_top(sort_by="memory", limit=10)
"What metrics are available for network traffic?"
→ Uses search_metrics(pattern="network")
"Get detailed info about kernel.all.load"
→ Uses describe_metric(name="kernel.all.load")
💡 Use Cases
Performance Troubleshooting
Ask Claude to:
- "Analyze current system performance and identify bottlenecks"
- "Why is my disk I/O so high?"
- "Which processes are consuming the most CPU?"
System Monitoring
- "Give me a health check of the production server"
- "Compare CPU usage over the last minute"
- "Monitor network traffic on eth0"
Capacity Planning
- "What's the memory utilization trend?"
- "Show me disk usage across all filesystems"
- "Analyze process resource consumption patterns"
🏗️ Architecture
┌─────────┐ ┌─────────┐ ┌─────────┐ ┌─────────┐
│ LLM │ ◄─MCP─► │ pcp-mcp │ ◄─HTTP─► │ pmproxy │ ◄─────► │ pmcd │
└─────────┘ └─────────┘ └─────────┘ └─────────┘
(REST API) (metrics)
- pcp-mcp: FastMCP server exposing PCP metrics via MCP tools
- pmproxy: PCP's REST API server (runs on port 44322 by default)
- pmcd: PCP metrics collector daemon
- Remote monitoring: Set
PCP_TARGET_HOSTto query a different pmcd instance via pmproxy
🔧 Development
# Install dependencies
uv sync --dev
# Run all checks
make check
# Individual commands
make lint # ruff check
make format # ruff format
make typecheck # ty check
make test # pytest with coverage
📖 Documentation
Full documentation at https://major.github.io/pcp-mcp
📄 License
MIT
Metadata
Release files for pcp-mcp 1.5.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pcp_mcp-1.5.1.tar.gz | 29.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pcp_mcp-1.5.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 68.3 kB
Release files / pcp_mcp-1.5.1.tar.gz
| Download URL | pcp_mcp-1.5.1.tar.gz |
|---|---|
| Size | 29.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cda2e1aa9a81414df32bc891e4c06b5dab72248c99c003539be522e4fa157fbd
|
|
BLAKE2b-256 checksum How to use checksums |
da15f6389efc426f9b7275d8f1439926c30e385545196b2a03fcb8051d68f68a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 26, 2026.
Transparency logRelease files / pcp_mcp-1.5.1-py3-none-any.whl
| Download URL | pcp_mcp-1.5.1-py3-none-any.whl |
|---|---|
| Size | 39.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
eb497f93807658b214e33c0071c6f1c1dc199ad11f1c660f37155814278b36f8
|
|
BLAKE2b-256 checksum How to use checksums |
052cbd6c5d9cd77f9315949936c65965249916c2e0acc1fcd605cc00103085b6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 26, 2026.
Transparency log