Skip to main content
Glama
io.github.zw008/vmware-debug

io.github.zw008/vmware-debug

VMware Debug

PyPI License: MIT

English | 中文

Maintainer: Wei Zhou · zhouwei008@gmail.com

Community-maintained open-source project; not an official VMware or Broadcom product.

Overview · Quick Start · MCP Configuration · Capabilities and Workflows · Safety and Audit · Troubleshooting · Companion Skills · Reference · License

Overview

Runs locally over stdio by default; see below for data sources and execution boundaries.

Disclaimer: Community-maintained open-source project, not affiliated with, endorsed by, or sponsored by VMware, Inc. or Broadcom Inc. "VMware" and "vSphere" are trademarks of Broadcom. Source is publicly auditable under the MIT license.

The diagnostic brain of the VMware skill family. You bring the symptom (an error, a log dump, a slow VM); this skill runs a systematic investigation, correlates events from the other skills into one timeline, ranks root-cause hypotheses, and tells you what to check next. It makes no VMware API calls and never executes fixes; case operations write a local ledger under $OPS_HOME, and every tool also writes a separate audit trail. Default stdio has no listener; optional authenticated HTTPS uses caller tokens and TLS certificate/key files. Remediation is routed to vmware-aiops (single op) or vmware-pilot (multi-step, gated), mirroring the vmware-harden → vmware-pilot advisor/executor split.

See skills/vmware-debug/SKILL.md for the full methodology, the event-envelope contract, and symptom routing.

Related MCP server: vmware-knight

Quick Start

Requires Python >=3.10 and uv.

uv tool install vmware-debug==2.3.3
vmware-debug --help

Target, credential and local data setup: setup guide.

Install

uv tool install vmware-debug==2.3.3
vmware-debug categories          # see which symptom categories it can diagnose

Offline / Air-Gapped Install (from source)

This project uses the modern PEP 517 build system (hatchling), so there is no setup.py by design — that is expected, not a missing file. If you cloned the source and hit ERROR: File "setup.py" or "setup.cfg" not found ... editable mode currently requires a setuptools-based build, your pip is older than 21.3 and cannot do an editable (-e) install with a non-setuptools backend. Editable mode is a developer convenience, not needed to run the tool — do one of:

# From the source tree — a normal (non-editable) install builds a wheel:
pip install .              # NOT  pip install -e .

# ...or upgrade pip first, and editable works too:
pip install --upgrade pip && pip install -e .

For a truly air-gapped host, build the wheels on a connected machine and copy them over — the target then needs no network:

# On a connected machine, collect this package + its dependencies as wheels:
pip wheel . -w dist        # → dist/*.whl   (or: uv build, for just this package)

# Copy dist/ to the air-gapped host, then install offline:
pip install --no-index --find-links dist vmware-debug

MCP Configuration

Copy this configuration into your MCP client's local stdio settings. The client must be able to find uvx; the initial package installation requires access to a package index.

{
  "mcpServers": {
    "vmware-debug": {
      "command": "uvx",
      "args": ["--from", "vmware-debug==2.3.3", "vmware-debug-mcp"]
    }
  }
}

Debug needs no vCenter target configuration or VMware account credentials; case operations write a local ledger and tool calls have a separate audit trail.

Capabilities and Workflows

MCP tools (14 — 7 read, 7 write)

The seven writes go to the local case ledger only; none reaches a VMware system.

Correlation — stateless, for a single look:

Tool

What

build_incident_timeline

[READ] Correlate pre-fetched events → timeline + spikes + ranked hypotheses + next-check ideas

list_symptom_categories

[READ] List recognised symptom categories + what to check for each

Investigation ledger — for an incident you will reason about over time:

Tool

What

open_case

[WRITE] Define the event; returns a case id and the grade this environment can reach

get_case_readiness

[READ] What grade this environment can reach, per symptom category, before you start

get_case_knowledge

[READ] Which knowledge formats are accepted, what is mounted, and which entries apply to a case

plan_case

[READ] What to fetch next — skill, tool and purpose per step; recomputed from the case's current state

list_cases

[READ] Cases, newest first

get_case

[READ] One case: scope, ledger sizes, grade history

record_case_hypothesis

[WRITE] Register a candidate explanation, or read the ledger of what supports and refutes each

submit_case_evidence

[WRITE] Record one retrieved fact, with its source, query and time basis

record_case_gap

[WRITE] Record what could not be retrieved, and how to close it

record_case_timeline

[WRITE] Correlate everything the case has collected into one timeline

grade_case

[WRITE] Recompute the conclusion grade from the ledger and record it

close_case

[WRITE] Record the final grade, archive, and name what was left open

Event envelope: {ts, source, severity, entity, text, fields}. The agent normalizes events from each source into this shape before handing them to debug, so debug has zero runtime dependency on the other packages. Keep each event's event_type in fields — the classifier matches it as well as the text, and most modern vSphere events are EventEx: the text is a generic boilerplate sentence, and only eventTypeId says what the event actually is.

Common Workflows

  1. Use vmware-debug categories to select a symptom category.

  2. Collect relevant evidence with Monitor, Aria or Log Insight and normalize it into events.json using the event envelope; Debug itself does not connect to those systems.

  3. Run vmware-debug triage --events events.json and inspect the timeline, hypotheses and next checks.

  4. If there are no events or a source is unreachable, check the source tool's configuration and connectivity and retain the evidence gap; missing data is not a healthy result.

  5. Hand an evidence-backed fix to AIops or Pilot under that tool's execution gates.

Safety and Audit

Security

CLI policy refusals print the reason and rule, exit with code 1, and retain one denied audit row.

The diagnostic engine connects to no vCenter/NSX/Aria and needs no VMware account credentials. Default stdio has no listener; optional HTTPS requires caller tokens and TLS files. Every tool writes a separate audit row in ~/.vmware/audit.db. Case tools also write the local ledger: evidence, gaps, hypotheses and grade history are append-only; timeline.md is regenerated from the evidence, and case.json holds the current grade and status. The same holds with several writers: every write to a case first takes that case's lock file (.ledger.lock, exclusive create), so two processes writing the same case in a shared $OPS_HOME are serialized instead of dropping each other's entries; every file is written under a temporary name and then moved into place, so a reader never sees a half-written file (on a file system without hard links, a new evidence file is instead created in place: still never overwritten, but it can be read half-written). A lock left behind by a crashed process is reported together with its holder and never deleted automatically; delete it by hand once you have confirmed no process is writing that case. Released versions 1.11.3 and earlier do not take this lock, so every machine sharing a case directory must upgrade. See SECURITY.md.

Remote access (HTTPS) and limiting tools

By default vmware-debug mcp speaks stdio to one local client and offers every tool. Two options change that (vmware-policy ≥ 1.21.0).

Serve over HTTPS so clients on other machines can connect. Every caller needs a bearer token:

vmware-audit token create alice          # prints the token once; give it to alice
vmware-audit token list                  # names only
vmware-audit token revoke alice          # refused from its next request, no restart
vmware-debug mcp --transport https --host 0.0.0.0 --port 8443 \
    --cert /etc/vmware-mcp/server.pem --key /etc/vmware-mcp/server-key.pem \
    --public-name mcp.example.com

Connect a client (Claude Code shown; any MCP client that supports streamable HTTP and custom headers works):

claude mcp add --transport http vmware-debug https://mcp.example.com:8443/mcp \
    --header "Authorization: Bearer $VMWARE_MCP_TOKEN"
{
  "mcpServers": {
    "vmware-debug": {
      "type": "http",
      "url": "https://mcp.example.com:8443/mcp",
      "headers": { "Authorization": "Bearer ${VMWARE_MCP_TOKEN}" }
    }
  }
}
  • The server will not start without a token, refuses Host/Origin values outside --public-name, and checks before it binds that unauthenticated requests get 401. Use a certificate your clients trust for those names.

  • Behind a TLS-terminating reverse proxy on the same machine use --transport http --host 127.0.0.1 --public-name mcp.example.com and pass the Authorization header through.

  • Behind a load balancer or gateway on another machine, keep --transport https (a self-signed certificate is fine), list in --public-name the host name the balancer sends as Host, and have it forward Authorization. Its health probe can use GET /healthz, which needs no token and returns only {"status": "ok"} (vmware-policy ≥ 1.23.0).

  • Send traceparent or X-Request-ID with each request to have it stored on the audit row; vmware-audit log --correlation-id ID then finds the calls behind one platform request.

  • The audit log records each caller as token:<name>. Calls naming different targets run in parallel; calls that name no target run one at a time, so name the target when several people share a server.

  • Everyone who can reach the endpoint acts with this server's account. Tokens identify callers; they grant nothing on the platform. Run one endpoint per privilege level.

  • Several people or roles on one endpoint: run vmware-audit roles enable once, then give each token a role (vmware-audit token create NAME --role reader, or a role in roles.yaml naming tools and targets; vmware-policy ≥ 1.24.0). A role limits what the token may call on this endpoint; it cannot grant more than the account has. See vmware-policy's README, "Roles for network callers".

Offer only read tools, plus the writes you choose:

vmware-debug mcp --expose read --allow-write close_case
# or: VMWARE_DEBUG_MCP_EXPOSE=read VMWARE_DEBUG_MCP_ALLOW_WRITE=close_case vmware-debug mcp

Tools not offered do not appear in the client's tool list. A bad value or an unknown write tool stops the server (exit 2). This limits what clients are offered; it is not authorization, so the account itself should be least-privilege.

Details: skills/vmware-debug/references/setup-guide.md ("Serving MCP over HTTPS", "Limiting which tools are offered").

Troubleshooting

For installation issues, see the installation instructions on this page. Check CLI arguments with --help before operating. Include only a minimal, redacted example when reporting a problem.

Companion Skills

The VMware Skills family contains 14 MCP servers and the shared Policy library. Choose tools by responsibility: vmware-skills.

Companion Skills

Need

Skill

Incident correlation / root cause

vmware-debug (this project)

Centralized log search

vmware-log-insight (feed its search_logs results here)

vCenter events and alarms

vmware-monitor

Metrics / anomalies

vmware-aria

Executing a fix

vmware-aiops (single op) / vmware-pilot (multi-step, gated)

Reference

Release history: RELEASE_NOTES.md.

Read-only self-test with your own model and agent host: model-fit self-test.

Upgrading to 2.0

2.0 renames 13 of its 14 MCP tools so every name starts with a verb (e.g. case_close → close_case, case_get → get_case, case_grade → grade_case). The full old → new table is in RELEASE_NOTES.md. Nothing else changes: same tools, parameters, safety gates and CLI commands. If an agent prompt, script or ~/.vmware/rules.yaml names a tool, update it — though deny rules written with the old names keep working with vmware-policy ≥ 1.18.1 (vmware-audit policy lists any rule the renames widened), and vmware-pilot ≥ 1.13 translates old names in saved workflows. If an install older than 2.0 shares that rules.yaml, give it vmware-policy ≥ 1.18.2 too: it matches each rule against both the old and the new name, so one file serves both.

License

MIT.

Available Tools

14 tools
build_incident_timelineA
Read-onlyIdempotent

[READ] Correlate already-fetched VMware events into one incident view.

WHEN: use this after you've pulled events for an incident from the data-source skills (vmware-monitor get_events/get_alarms, vmware-aria list_alerts/list_anomalies, vmware-log-insight search_logs/aggregate_logs, vmware-nsx) — feed them here to find what correlates and where to look next. Not sure which events to pull? Run list_symptom_categories first. This tool does NOT fetch anything itself.

RETURNS: {event_count, window, binning, classification, spikes (strongest anomalous bins), spikes_total, hypotheses (ranked root-cause candidates, each with a suggested_check), next_checks (which skill/tool to run next)}. Read binning for the resolution you were given, and classification for how much of the stream matched nothing — the ranking describes only the part that did.

GOTCHAS: read-only, stateless, no network — nothing is executed. Remediation routes to vmware-aiops (single fix) or vmware-pilot (multi-step). A malformed event returns {error, hint} naming the offending index.

Inputs: events (required), top_n, bin_seconds, z_threshold.

close_caseA

[WRITE] Record the final grade and archive the case — step 08.

WHEN: when the investigation is finished, or is being handed over. Closing turns a working folder into a record other people rely on, so it computes and records the grade rather than accepting one.

RETURNS: {case_id, state, grade, open_gaps, path, note}. open_gaps names anything still blocking a hypothesis at the moment of closing — stated here rather than left in the file for someone to find.

GOTCHAS: a closed case is not closed again and its record is never rewritten. To reopen the question, open a new case that cites this one, so the original conclusion and whatever changed it both stay readable.

Inputs: case_id (required).

get_caseA
Read-onlyIdempotent

[READ] One case: its scope, its ledger sizes, and its grade history.

WHEN: to pick up an investigation, or to see why a case sits at the grade it does. Returns counts and identifiers rather than the whole ledger — read the case folder itself (the path from open_case) for full evidence bodies.

RETURNS: {case_id, path, state, grade, opened_at, scope, evidence_count, sources, gap_count, blocking_gaps, grade_history}. sources is the distinct skills evidence came from, which is what corroboration is counted in.

Inputs: case_id (required).

get_case_knowledgeA
Read-onlyIdempotent

[READ] What the knowledge layer accepts, and what is mounted.

WHEN: when someone asks what can be added to make conclusions stronger, or when a case will not reach Confirmed and you need to say why in terms they can act on. This is the answer to "which knowledge formats do you take" — the first question anyone mounting a library asks.

RETURNS: {root, sections, entries, with_applies_to, by_source, unreadable, unsupported, formats, needs_conversion, note} — plus {applicable, decisive_here} when a case_id is given.

formats lists every extension read and how each carries its metadata: Markdown front-matter, YAML/JSON whole-file, JSONL per line, CSV/TSV per row, and plain text with a sibling .yaml. needs_conversion names the ones that must become Markdown first (PDF, DOCX, PPTX, HTML).

GOTCHAS: an entry is decisive ONLY if its applies_to block was checked against the case scope and passed — matching is by version applicability, never by similarity, because an entry written for the wrong build reads exactly like the right one. An entry with no applies_to can support a hypothesis but can never make a case Confirmed. A constraint the case scope cannot answer is not a match either: silence is not a pass.

Inputs: case_id.

get_case_readinessA
Read-onlyIdempotent

[READ] What strength of conclusion can this environment reach?

WHEN: before starting an investigation, or when a case will not go higher and you want to know whether that is fixable. Answering this first is worth far more than discovering it halfway through.

RETURNS: {classes, categories, unrecognised_skills, note}. A name that matched no skill in the catalogue comes back in unrecognised_skills rather than being absorbed into "not installed" — otherwise a typo reads as advice to install something you already have. Per evidence class: whether it is available, through which tools, and if not, how_to_supply. Per symptom category (storage, network, compute, ha_drs, configuration, accelerator, kubernetes, hardware, host_lifecycle, power_lifecycle, auth, platform, licensing, data_collection): a ceiling and the independent_sources behind it. There is deliberately no single score — "readiness 78%" cannot be acted on, "storage reaches Probable, hardware reaches Candidate" can.

GOTCHAS: two classes served by the SAME skill count as one source, so two available classes do not always mean Probable. The hardware class is unavailable no matter what is installed — nothing in this family reaches below ESXi — and the knowledge class becomes available only when entries are mounted under $OPS_HOME/knowledge/.

Inputs: available_skills.

grade_caseA

[WRITE] Compute and record the conclusion grade — steps 07/08.

WHEN: when you think the investigation has reached a conclusion, or to record where it stands before handing it over.

There is deliberately NO parameter for the grade. You cannot state a conclusion level; it is recomputed from the ledger on every call. If you disagree with the result, change the ledger — submit the evidence that is missing, or record the gap that is blocking it.

The levels: Candidate (a hypothesis exists); Probable (at least two INDEPENDENT sources agree — two calls to the same skill are one source — and nothing outstanding could overturn it); Confirmed (that, plus a decisive item: a direct hardware diagnostic, a version-checked knowledge-base entry, or a vendor SR, and no gap left open); Excluded (an observation that actually rules the hypothesis out — "we looked and found nothing" is a gap, not an exclusion). Exclusion is per hypothesis, counting only sources that falsify THAT hypothesis; the case is Excluded only when every registered one is. A hypothesis contradicted but not yet ruled out holds the case at Candidate. Otherwise the grade counts only evidence that falsifies nothing.

RETURNS: {grade, previous, direction, reasons, ceiling, ceiling_reasons, rules_source, rules_origin, hypotheses}. hypotheses lists every registered hypothesis as {id, status: open|excluded}. direction is initial/up/down/unchanged — grades may go DOWN, and the history records it when they do.

GOTCHAS: on a stock install ceiling is "probable", because Confirmed needs a decisive source and there is neither a hardware-diagnostic channel nor a knowledge library mounted yet. That is a real limit, not a caution. Every grading is appended to conclusion.md and none is ever rewritten.

Inputs: case_id (required).

list_casesA
Read-onlyIdempotent

[READ] List investigation cases, newest first.

WHEN: to find the id of a case you or someone else opened earlier. Returns the family list envelope {items, returned, limit, total, truncated, hint}; each item is {case_id, summary, state, grade, opened_at}. A case whose folder is damaged appears with state="unreadable" rather than vanishing from the list.

Inputs: limit.

list_symptom_categoriesA
Read-onlyIdempotent

[READ] List the symptom categories vmware-debug recognises, each with example keywords and a suggested next check (which skill/tool to run). Takes no parameters. Use this when you don't yet know what to look at — it turns "something's wrong" into concrete investigation steps. Then gather the events those checks name and pass them to build_incident_timeline. Returns the family list envelope {items, returned, limit, total, truncated, hint}; each item is {category, example_keywords, suggested_check}. The routing table is a fixed constant, so truncated is always false and total exact — this is every category, not a page. Read-only; no network access.

Inputs: no named parameters.

open_caseA

[WRITE] Open an investigation case — step 01, define the event.

WHEN: at the start of an incident you expect to reason about rather than glance at. For a one-off lookup use build_incident_timeline alone.

RETURNS: {case_id, path, state, grade, ceiling, ceiling_reasons, next}. Read ceiling now — it is the best grade this install can reach at all.

GOTCHAS: writes only under $OPS_HOME, never to a VMware system, and never over an existing case.

Inputs: summary (required), determined_by (required), objects, window_end, +2 more.

plan_caseA
Read-onlyIdempotent

[READ] What to fetch next for this case — step 02, recomputed each call.

WHEN: right after open_case, and again after each round of evidence. It is not a checklist: submit something and the next plan is shorter, lose a source and it routes around it.

RETURNS: {category, category_signals, steps, already_covered, held_back, unavailable, ceiling, note}. Steps are interleaved across evidence classes, so you get breadth before depth — corroboration is counted in distinct sources, which is what actually moves the grade. Each step is {evidence_class, skill, tool, purpose, objects, window, degraded} — call that skill's tool, then submit the result with submit_case_evidence.

GOTCHAS: unavailable is the important half. A source this install cannot reach is listed there with how_to_supply rather than left out, so the gap is visible now instead of when the conclusion refuses to firm up. An empty steps is never silent — note says whether everything reachable is already in, or whether nothing here can be reached. category_signals names the words that chose the category, and any category that also matched — check it first, since the rest runs off that one word.

Inputs: case_id (required), category, max_steps, available_skills.

record_case_gapA

[WRITE] Record something the investigation could NOT obtain.

WHEN: any time a fetch failed, was refused, returned nothing, or the data simply does not exist in this environment. This is the tool that keeps a case honest: an unrecorded gap makes it look better supported than it is.

RETURNS: {case_id, gap_id, grade, reasons}.

GOTCHAS: recording a gap does not punish the case for the evidence it does have — a missing confirmation caps the grade, it does not demote it. Writing gaps down is meant to be free.

Inputs: why (required), what (required), case_id (required), how_to_close (required), +2 more.

record_case_hypothesisA

[WRITE] Register a candidate explanation — step 06. Called without statement it writes nothing and only reads the hypothesis ledger.

WHEN: as soon as you have a theory worth testing, and again to see where each one stands. Pass statement to add one; omit it to just read.

Every hypothesis gets an id (H1, H2, …). Those ids are what record_case_gap(blocks=[...]) and submit_case_evidence(falsifies=[...]) refer to, and an id that was never registered is REFUSED rather than ignored — a dangling reference blocks nothing and falsifies nothing, which quietly reports a stronger case than you have.

RETURNS: {case_id, added, hypotheses, note}. Each entry carries its status: refuted (ruled out by grade_case's rule), blocked (a gap is in the way, with the gap id and how to close it), or open. refuted_by lists every falsifying item; the first next step says when more sources are needed. Status is computed from what points at the hypothesis, never asserted.

GOTCHAS: refuted outranks blocked. Once an observation settles the question, a missing measurement no longer matters.

Inputs: case_id (required), statement.

record_case_timelineA

[WRITE] Correlate everything this case has collected — steps 04/05.

WHEN: once evidence is in. Unlike build_incident_timeline, this takes no events: it reads the payloads already submitted, so the result is reproducible from the case folder alone months later, on a machine with access to nothing.

RETURNS: {event_count, window, binning, classification, spikes, spikes_total, hypotheses, evidence_without_events, evidence_without_events_detail, rejected, note} and writes timeline.md.

GOTCHAS: note distinguishes three states that all show zero events — no evidence submitted at all, evidence that carried none, and a genuinely quiet window — and names which items carried none, with what they held instead. rejected names any row that could not be read, with the evidence item it came from; dropping those silently would shrink the picture the conclusion rests on. Submit a read tool's raw result as payload for its events to reach here — a summary of the result carries no rows, and submit_case_evidence says so at the time.

Inputs: case_id (required), top_n, bin_seconds, z_threshold.

submit_case_evidenceA

[WRITE] Record one retrieved fact — steps 02/03 of the evidence loop.

WHEN: after every read-tool call you intend to reason from.

RETURNS: {case_id, evidence_id, payload_events, payload_note, grade, reasons} — the resulting grade, so you need no second call to see whether this changed anything, and what the payload was read as, so a summary submitted in place of a result is visible here rather than as a zero from record_case_timeline later.

GOTCHAS: a fetch that failed or came back empty goes to record_case_gap, not here.

Inputs: case_id (required), summary (required), source_tool (required), source_skill (required), +9 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.4/5.0

    Scored across 14 tools

    Disambiguation4/5

    Most tools are clearly separated by lifecycle stage and action, but build_incident_timeline and record_case_timeline both perform event correlation, and plan_case, get_case_readiness, and get_case_knowledge all provide advisory information. The detailed descriptions do a good job of distinguishing them, but they require careful reading.

    Naming Consistency5/5

    All 14 tool names use snake_case and begin with a clear verb (build_, list_, open_, get_, submit_, record_, grade_, plan_, close_). The pattern is highly predictable and consistent across reads and writes.

    Tool Count5/5

    14 tools is well-scoped for a case-based investigation workflow that includes setup, evidence handling, grading, readiness, planning, knowledge, and closure. Each tool appears to earn its place rather than padding the surface.

    Completeness4/5

    The server covers the full investigation lifecycle from open_case through close_case, including evidence, gaps, hypotheses, timelines, grading, and readiness. Minor gaps exist around directly reading case evidence bodies or fetching events, but those are intentionally delegated to external data-source skills and the case folder.

    Maintenance

    ActivityActive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables log analysis through MCP tools for searching logs, retrieving error contexts, and summarizing incidents with self-verified root-cause hypotheses.
      11 npm
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables AI-assisted management of vCenter Server and standalone ESXi hosts, including lifecycle, deployment, guest operations, cluster management, datastore browsing, alarms, and investigations through natural language.
      60
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables MCP clients to interactively triage 4G/5G modem logs by summarizing logs, detecting fault signatures with evidence, retrieving relevant troubleshooting knowledge, and generating root-cause reports.
      MIT
    • A
      license
      B
      quality
      B
      maintenance
      Enables AI assistants to perform comprehensive read-only diagnostics of VMware ESXi hosts, covering CPU Ready, disk latency, snapshots, datastore usage, hardware health, events, and performance history. It guarantees no write operations, helping users identify bottlenecks and infrastructure issues safely.
      13
      28 PyPI
      MIT