KVM MCP Server
@steveydevey
About KVM MCP Server
An MCP server for KVM hypervisors
Basic information
Config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"kvm-mcp": {
"command": "python3",
"args": [
"-m",
"venv",
".venv"
]
}
}
}Tools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is KVM MCP Server?
A JSON-RPC server for managing KVM virtual machines through a unified interface. It centralizes control and monitoring of KVM VMs using a standardized protocol, replacing multiple command-line tools like virsh and virt-install.
How to use KVM MCP Server?
After installing prerequisites (Python 3.6+, KVM/libvirt, a configured network bridge and VM storage directory), clone the repository, create a virtual environment, install dependencies from requirements.txt, and edit config.json to match your environment. Start the server with python3 kvm_mcp_server.py and send JSON-RPC commands; example scripts (create_vm.sh, get_vnc_ports.sh) are provided.
Key features of KVM MCP Server
- VM lifecycle management (create, start, stop, reboot, list)
- Network management using bridges (default
brforvms) - Storage management with qcow2 disk format
- VNC display support with automatic port assignment
- Installation from ISO or local CDROM
- Connection pooling, caching, and asynchronous processing
Use cases of KVM MCP Server
- Automate VM provisioning and lifecycle management
- Remotely control and monitor KVM virtual machines
- Standardize VM configuration across infrastructure
- Integrate VM operations into scripts or pipelines
- Optimize performance with connection pooling and caching
FAQ from KVM MCP Server
What are the prerequisites for running KVM MCP Server?
Python 3.6 or higher, KVM and libvirt installed on the host system, the network bridge brforvms configured, and a VM storage directory (default /vm/) created.
How do I configure the server?
Edit config.json to set default disk path, ISO, memory, vCPUs, disk size, network bridge, and ignition settings. Environment variable overrides are supported for each setting (e.g., VM_DISK_PATH, VM_DEFAULT_MEMORY).
Can I bypass the cache to get fresh VM information?
Yes, pass "no_cache": true in the list_vms call arguments to force a fresh query from libvirt.
What performance optimizations are included?
Connection pooling (configurable pool size, automatic recovery), VM info caching (configurable TTL and max size), asynchronous processing for better concurrency, and structured logging with performance metrics.
How do I monitor server health and performance?
The server logs to kvm_mcp.log (rotated at 10MB) with timing, connection pool status, cache hit/miss ratios, and operation metrics. Performance statistics are also available through the monitoring features.
More Other MCP servers
ICSS
chokcoco不止于 CSS
FastMCP v2 🚀
jlowin🚀 The fast, Pythonic way to build MCP servers and clients.
MCP Go 🚀
mark3labsA Go implementation of the Model Context Protocol (MCP), enabling seamless integration between LLM applications and external data sources and tools.
🚀 Model Context Protocol (MCP) Curriculum for Beginners
microsoftThis open-source curriculum introduces the fundamentals of Model Context Protocol (MCP) through real-world, cross-language examples in .NET, Java, TypeScript, JavaScript, Rust and Python. Designed for developers, it focuses on practical techniques for building modular, scalable,
IDA Pro MCP
mrexodiaAI-powered reverse engineering assistant that bridges IDA Pro with language models through MCP.
Comments