claude-rocm-mcp
Claude ROCm GPU Monitor
Linux上のClaude Desktop向け読み取り専用AMD GPU監視ツール。Claudeが「トレーニングは正常に動作しているか?」「GPUの温度は?」「VRAMの残量は?」「どのプロセスがカードを使用しているか?」といった質問に答えられるようになります。プロセス終了、クロック変更、その他実行中のワークロードへの干渉機能は一切ありません。
rocm-smi(およびオプションで amdgpu_top)を呼び出し、5つの厳格な読み取り専用ツールを提供します。プロセス終了、クロック/電力のオーバーライド、ファン制御は行いません。それらが必要な場合は、gpu-killのようなツールを使用してください。
要件
Linux(AMD GPU搭載:RDNA2/3/4コンシューマーカード — RX 6000/7000/9000, R9700 — およびCDNAデータセンターカード)。
amdgpuカーネルモジュールがロードされていること(最新のUbuntu/Debian/Fedoraでは標準)。rocm-smiがインストールされていること:sudo apt install rocm-smi # minimal # or a full ROCm stack: # https://rocm.docs.amd.com/projects/install-on-linux/
一部のメトリクス(クロック、電力、詳細な温度)には新しいROCmリリースが必要です。カードやドライバーがメトリクスをサポートしていない場合、ツールはエラーではなく null を返します。
Related MCP server: claude-terminal-mcp
インストール (Claude Desktop)
Releases ページから最新の
ROCm.mcpbをダウンロードします。Claude Desktopで Settings → Extensions を開きます。
下部の Extension Developer までスクロールし、Install Extension をクリックして
.mcpbファイルを選択します。拡張機能を有効にします。Claudeのツールピッカーに
rocm-gpu-monitor:というプレフィックスが付いたツールが表示されます。
ツール
ツール | 機能 |
| ワンショットの概要:名前、使用率%、VRAM使用量/合計、温度(エッジ/ジャンクション/メモリ)、電力平均/最大、ファン%/RPM。 |
| 完全な |
| GPUを使用している計算プロセス(KFD PID)、VRAM使用量、カードインデックス。 |
| 固定間隔でN回サンプリングし、生のフレームとカードごとの最小/最大/平均統計を返します。 |
| インストール済みのROCm/HIPパッケージ、ドライバーバージョン、 |
すべてのツールにはMCPの readOnlyHint: true / destructiveHint: false / openWorldHint: false アノテーションが付与されています。
プロンプト例
「トレーニングは安定しているか?20秒間GPUを監視して。」
「現在のPyTorchプロセスはどれくらいVRAMを使っている?」
「GPUはサーマルスロットリングを起こしているか?ジャンクション温度は?」
「インストールされているROCmのバージョンと、ドライバーがロードされているか教えて。」
プライバシーポリシー
この拡張機能は完全にローカルマシン上で動作し、以下のプログラムのみを読み取り専用で呼び出します:
rocm-smi— AMDカーネルドライバーにデバイスメトリクスを問い合わせます。amdgpu_top(インストールされている場合) — より詳細なメトリクスを取得します。dpkg -l— インストールされているROCm関連パッケージを名前/バージョンで列挙します。lsmod—amdgpuカーネルモジュールがロードされているか確認します。which— 起動時に上記のバイナリの場所を特定します。
データがマシンから外部へ送信されることはありません。 この拡張機能はネットワークI/Oを行わず、ソケットを開かず、標準のプロセスstdout/stderr(Claude Desktopのログディレクトリにキャプチャされる)以外にファイルを書き込みません。GPUの状態(クロック、電力、ファン)を変更したり、プロセスを終了させたり、実行中のワークロードに干渉したりすることはできません。すべてのツールは厳格に読み取り専用です。
Claudeが参照できる情報には、GPUモデルとファームウェアバージョン、現在のVRAM使用量、温度/クロック/電力の読み取り値、GPUを使用しているプロセスのPIDとVRAM使用量、インストールされているROCm関連パッケージのリストが含まれます。これらを機密情報とみなす場合(例:共有マシン上の実行中プロセスPIDのリストなど)、この拡張機能を有効にしないでください。
トラブルシューティング
「rocm-smi is not installed」 — インストールしてください(sudo apt install rocm-smi)。Debian以外のディストリビューションを使用している場合は、AMDのROCmインストール手順に従ってください。
新しいGPUで多くのフィールドが null になる — 一部のメトリクス(クロック、電力、温度)は rocm-smi を通じて公開されるファームウェアのサポートに依存します。非常に新しいカード(例:RDNA4/R9700)では、-a --json がデータを返しても、個別の rocm-smi --showclocks/--showpower が「No JSON data to report」と報告する場合があります。この拡張機能はカバレッジを最大化するために -a --json を主要なソースとして使用します。特定のフィールドがカードでサポートされていない場合、エラーではなく null になります。
権限エラー — rocm-smi は通常root権限なしで実行されます。権限エラーが発生する場合は、Claude Desktopを実行しているユーザーが render および video グループに属しているか確認してください:
sudo usermod -aG render,video $USER
# log out and back in開発
サーバーはnpm依存関係ゼロの約300行のNode.jsスクリプトです。.mcpb を再ビルドするには:
cd bundle-source
zip -j ../ROCm.mcpb manifest.json package.json server.js README.md LICENSE icon.pngライセンス
MIT。LICENSE を参照してください。
関連
claude-terminal-mcp — シェル、ファイルシステム、バックグラウンドジョブ。
claude-linux-mcp — X11デスクトップ制御(スクリーンショット、マウス、キーボード、ウィンドウ、クリップボード)。
Available Tools
5 toolsgpu_metricsARead-only
Full rocm-smi -a --json output for every GPU (clocks, voltages, PCIe link width/speed, firmware versions, per-engine activity, throttle status, energy counters). Use when gpu_status is not enough. The shape is rocm-smi’s native JSON, unmodified.
Inputs: no named parameters.
gpu_processesARead-only
List compute processes using the GPU (KFD PIDs) with their VRAM usage and card index. Returns an empty list when no compute workloads are running.
Inputs: no named parameters.
gpu_statusARead-only
One-shot summary of all AMD GPUs: product name, GPU utilization %, VRAM used/total bytes and %, edge/junction/memory temperatures, average and max power, fan speed % and RPM. Returns one entry per card. Fields that the card does not support are returned as null (not omitted).
Inputs: no named parameters.
gpu_watchARead-only
Take N snapshots of gpu_status at a fixed interval and return both the raw frames and per-card min/max/avg statistics for utilization, temperature, power, and VRAM usage. Useful for answering “is this training run stable?”. Default: 5 samples at 1000ms intervals.
Inputs: samples, interval_ms.
rocm_infoARead-only
Report the rocm-smi version, kernel driver version, whether the amdgpu module is loaded, installed ROCm/HIP/HSA packages (from dpkg), and whether amdgpu_top is available. Useful for checking ROCm install health before running workloads.
Inputs: no named parameters.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 5 tools
Each tool serves a distinct purpose: raw metrics, summary status, process listing, time-series snapshots, and install health check. No overlap in functionality.
All tool names follow a consistent snake_case pattern with a clear noun-based prefix (gpu_ or rocm_), making them predictable and easy to distinguish.
Five tools is appropriate for a monitoring-focused server, covering essential needs without being excessive or insufficient.
The tool set covers core monitoring, process insight, and installation health, but lacks a way to reset or configure GPU parameters, though that may be out of scope.
Maintenance
Related MCP Connectors
WHOOP recovery, strain, sleep and workouts in Claude via official WHOOP OAuth. Free, open source.
Garmin data in Claude: 135 tools — activities, sleep, HRV, training, workouts. Free, open source.
Real-time Claude & Anthropic news from your own Claude — free, no API key.
Uptime, SSL, DNS and domain monitoring you can talk to from Claude or any MCP client.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceProvides system monitoring and management capabilities for Claude CLI, allowing users to view system information, track resource usage, and manage processes through natural language commands.-
- AlicenseAqualityCmaintenanceGive Claude Desktop terminal, filesystem, and background-job access on your local Linux machine. Zero-dependency MCP extension, MIT-licensed.85MIT
- AlicenseAqualityDmaintenanceEnables Claude to monitor CPU, memory, disk, processes, network connections, Docker containers, and system logs for system diagnostics and troubleshooting.5MIT
- AlicenseNot gradedqualityCmaintenanceEnables SSH-based read-only monitoring of Linux vServers via Claude, allowing queries for system metrics, logs, network info, and health check reports.MIT