Skip to main content
Glama

conserver-tools

Tools for interacting with serial consoles managed by a conserver daemon.

This repo provides two interfaces with the same libconserver.py protocol implementation:

Both allow AI agents (e.g. Claude) to connect to serial consoles, send commands, read output, and manage console sessions.

Features

  • Connect to a console in attach, spy (read-only), or force mode

  • Send commands and read output interactively

  • Send control characters (Ctrl-C, Ctrl-D, etc.)

  • Expect scripting for automated interaction (wait for patterns, branch on output)

  • Query who is connected to consoles

  • Disconnect users from consoles

  • SSL/TLS and GSSAPI/Kerberos authentication

  • Multiple transports: stdio, SSE, and streamable-http

Related MCP server: console-switch-mcp

Installation

pip install mcp-conserver

Or install from source:

git clone https://github.com/vivier/mcp-conserver.git
cd mcp-conserver
python -m venv venv
source venv/bin/activate
pip install -e .

Configuration

The server reads ~/.consolerc for default master server, port, and username:

config * {
  master conserver.example.com;
  port 782;
  username myuser;
}

All defaults can be overridden per tool call.

Usage with Claude Code

Add to .mcp.json in your project directory (see mcp.json.example):

{
  "mcpServers": {
    "conserver": {
      "command": "mcp-conserver"
    }
  }
}

To use SSE or streamable-http transport instead of stdio:

mcp-conserver --transport sse --host 0.0.0.0 --port 9820

Tools

Tool

Description

console_connect

Connect to a console (attach/spy/force)

console_close

Disconnect and close a session

console_list_sessions

List active sessions

console_send

Send text and return output

console_read

Read latest console output

console_send_control

Send control characters (Ctrl-C, Ctrl-D, etc.)

console_expect

Run expect-like scripts (wait for patterns, send on match)

console_who

Show who is connected

Architecture

Uses libconserver.py, a pure Python implementation of the conserver client protocol, supporting SSL/TLS (anonymous DH), GSSAPI/Kerberos authentication, and multi-hop server redirects.

Each console session runs a background reader thread that continuously drains the socket into a buffer, ensuring no data is lost between tool calls.

License

GPLv2 - see LICENSE.

Tool Schema Changelog

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

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      B
      quality
      D
      maintenance
      Enables control of OpenSimulator virtual world servers through console commands, supporting region management, user administration, terrain editing, object manipulation, and HyperGrid operations via the REST console API.
      3
      3
      -
    • A
      license
      A
      quality
      D
      maintenance
      Enables control of network switches via serial console ports, supporting Huawei, H3C, and Cisco devices for command execution and configuration.
      6
      MIT
    • F
      license
      Not graded
      quality
      B
      maintenance
      Enables sharing two serial consoles between a local operator and MCP agents, allowing command execution and status monitoring on connected devices.
      -
    • A
      license
      B
      quality
      B
      maintenance
      Enables AI agents to open persistent interactive terminal sessions with network devices over SSH, Telnet, TCP console, or serial, write raw commands including nested ssh/telnet transitions, and read full output without requiring a particular prompt format. It supports multiple concurrent sessions and keeps credentials/secrets out of MCP arguments or audit logs.
      7
      MIT