Skip to main content
Glama
samdoran

mcp_linux_ssh

by samdoran

MCP Server to run commands over SSH

⚠️ This is an early prototype. Use at your own risk. ⚠️

Getting started

python -m venv .venvs/mcp
.venvs/mcp/bin/python -m pip install -e .

Run the MCP server with .venvs/mcp/bin/mcp-linux-ssh

To have an MCP client run the application, point it at realpath .venvs/mcp/bin/mcp-linux-ssh.

Here's an example configuration for Claude Desktop:

{
    "mcpServers": {
        "linux_ssh": {
            "command": "/Users/sdoran/Developer/mcp_linux_ssh/.venvs/mcp/bin/mcp-linux-ssh",
            "env": {
                "TMPDIR": "/tmp"
            }
        }
    }
}

Create a standalone executable

Use shiv to create portable executable.

mkdir build
shiv -o build/mcp_linux_ssh --console-script mcp-linux-ssh .

Logging

Commands and the hosts they are run on are logged to a local file that is rotated once it reaches five megabytes in size. The file location depends on the platform running the MCP server.

Linux: ~/.local/share/logs/mcp-linux-ssh.log

macOS: ~/Library/Logs/mcp-linux-ssh.log

Available Tools

6 tools
get_cpu_infoCPU informationC
Read-only

Get detailed information about system CPUs

ParametersJSON Schema
NameRequiredDescriptionDefault
hostYes

TDQS

C2.7/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The annotations already declare readOnlyHint=true, indicating a safe read operation. The description 'Get detailed information' is consistent but adds no further behavioral context (e.g., what 'detailed' means, rate limits, or side effects). Given annotations are present, the bar is lower, so a score of 3 is appropriate.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, front-loaded sentence, but it is too minimal. It omits crucial details like the host parameter, making it less helpful. It earns a 3 for being concise without being verbose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description should clarify what 'detailed information' includes. It does not. Additionally, it fails to contextualize the host parameter. The tool is simple, but the description still lacks completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0% (the required 'host' parameter has no description). The description fails to explain the host parameter's purpose or format, leaving the agent to guess its meaning. For low coverage, the description must compensate, which it does not.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Get detailed information about system CPUs' clearly states the action (Get) and the resource (system CPUs), adequately distinguishing it from sibling tools like get_disk_info or get_processes. However, it could be more precise by mentioning the required host parameter.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus its siblings (e.g., get_disk_info, get_service_status). An agent would need to infer usage purely from the name and context, leaving ambiguity.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_disk_infoDisk informationC
Read-only

Get details about the system filesystems and free space

ParametersJSON Schema
NameRequiredDescriptionDefault
hostYes

TDQS

C2.9/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate readOnlyHint=true, so the description's burden is lighter. The description says 'get details', which is consistent, but adds no extra context about permissions, rate limits, or error handling.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single short sentence (8 words), which is concise but overly terse. It is front-loaded with 'Get details', but lacks critical information about parameters and return values, making it incomplete rather than efficiently compact.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With one required parameter and no output schema, the description should explain what 'details' include (e.g., filesystem names, sizes, usage). It omits this entirely, leaving the agent without enough context to understand what the tool returns.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The sole parameter 'host' has no schema description (0% coverage), and the description fails to mention or explain it. The phrase 'system filesystems' is ambiguous and may mislead the agent into thinking no host is needed. Description does not add meaning beyond the raw schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states the tool retrieves details about system filesystems and free space. The verb 'get' and resource 'disk info' are specific and distinguish this from sibling tools like get_cpu_info or run_ssh.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives. It does not mention when to prefer siblings like get_cpu_info or get_service_status, nor does it contraindicate usage scenarios.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_processesGet running processB
Read-only

List all processes on a system sorted in descending order by CPU

ParametersJSON Schema
NameRequiredDescriptionDefault
hostYes

TDQS

B3.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already provide readOnlyHint=true, so the description doesn't need to restate that. The description adds the behavioral detail of descending CPU sort order, but lacks other traits like error handling or required permissions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single, clear sentence with no redundant words. The description is appropriately sized for a simple tool.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description omits any indication of what the output is (e.g., list of process names, PIDs, CPU percentages). Since there's no output schema, this information is needed for complete understanding. Also, no mention of behavior with unreachable hosts or empty results.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, and the description provides no additional meaning for the 'host' parameter beyond its title. The tool description fails to explain what the host parameter expects (e.g., IP, hostname) or any constraints.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it lists processes, specifies the resource (processes on a system), and adds a distinct detail (sorted by CPU descending). This differentiates it from sibling tools like get_cpu_info or get_disk_info.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool over alternatives like get_cpu_info or run_ssh_read_only. The description simply states what it does, with no context on when it's appropriate or not.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_service_statusService statusB
Read-only

Get details on a systemd unit

ParametersJSON Schema
NameRequiredDescriptionDefault
hostYes
unitYes

TDQS

B3.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, and the description's 'get details' aligns with a read operation. It adds no additional behavioral context beyond what annotations provide, but does not contradict them.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence with no wasted words. While concise, it could be slightly expanded to clarify parameters without losing efficiency.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the lack of output schema and 0% parameter documentation, the description fails to convey what 'details' are returned or how to correctly specify parameters. It is incomplete for a tool with two required parameters.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, and the description does not explain the meaning of 'host' or 'unit' parameters. The agent must infer their roles, which may lead to incorrect usage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Get details on a systemd unit' uses a specific verb ('get') and resource ('systemd unit'), clearly distinguishing it from siblings like get_cpu_info, get_disk_info, and get_processes which target different system resources.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies when to use (when you need details on a systemd unit) but provides no explicit guidance on when not to use it or alternatives among sibling tools. It lacks comparative context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

run_sshRun SSHC

This command could make changes to the system. Care should be taken to not disable ssh or modify files such as /etc/sudoers, etc/password, or /etc/shadow so as to render tho system inaccessible.

It can use sudo but should not prompt for password input. The sudo settings shoould allow passwordless sudo on the remote machine.

When using systemctl, make sure to add --no-pager to prevent the command from hanging.

ParametersJSON Schema
NameRequiredDescriptionDefault
hostYes
commandYes

Output Schema

ParametersJSON Schema
NameRequiredDescription

No output parameters

TDQS

C2.3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses some behavioral traits: it can make changes, requires passwordless sudo, and advises on systemctl usage. However, it omits key details like connection prerequisites, error handling, and output behavior. With no annotations, the description provides moderate transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is relatively concise with three sentences, each adding useful information. It front-loads the warning about system changes and avoids unnecessary verbosity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description lacks completeness for safe and effective usage. It does not mention network connectivity, SSH key setup, command execution environment, or return value format, which are critical for a mutation tool. The presence of an output schema is not leveraged in the description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has a schema coverage of 0% (no parameter descriptions). The description does not explain the host or command parameters, providing no added meaning beyond the parameter names.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose2/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description does not explicitly state that the tool runs an arbitrary command on a remote host via SSH. It only says 'This command could make changes to the system,' which is vague and does not clearly differentiate from sibling tools like run_ssh_read_only.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives like run_ssh_read_only. The description includes warnings but no explicit when-to-use or when-not-to-use conditions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

run_ssh_read_onlyRun SSH read onlyB

Only run commands that would not make changes to the system. sudo is not allowed.

When using systemctl, make sure to add --no-pager to prevent the command from hanging.

ParametersJSON Schema
NameRequiredDescriptionDefault
hostYes
commandYes

Output Schema

ParametersJSON Schema
NameRequiredDescription

No output parameters

TDQS

B3/5.0
Behavior1/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description explicitly claims the tool only runs read-only commands, but the 'readOnlyHint' annotation is false, creating a contradiction. Also lacks disclosure of error handling or behavior for write commands.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is very concise (3 sentences) and front-loads the critical constraint (read-only). Every sentence adds value, though the contradiction undermines its effectiveness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite having an output schema, the description lacks behavioral detail (e.g., error handling, what happens if a write command is attempted) and provides no parameter context, making it incomplete for safe invocations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage and no mention of parameters in the description, the agent gets no additional meaning for 'host' or 'command' beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: running read-only commands via SSH, and the name reinforces this. It distinguishes from sibling 'run_ssh' by specifying the read-only constraint.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives usage guidance: sudo is not allowed and systemctl needs --no-pager. However, it does not explicitly state when to use this tool versus alternatives, though it's implied by the read-only focus.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

TDQS

B3.3/5.0
Disambiguation5/5

Each tool targets a distinct system resource or action. The two command execution tools are clearly separated by read-only vs. writable behavior, eliminating ambiguity.

Naming Consistency5/5

All tool names follow a consistent snake_case pattern: informational tools use 'get_' prefix and execution tools use 'run_' prefix, making the set predictable.

Tool Count5/5

Six tools cover the essential operations for a Linux SSH management server—information gathering and command execution—without being excessive or sparse.

Completeness4/5

The set covers CPU, disk, processes, services, and generic command execution. Missing memory or network info, but the core diagnostic and action capabilities are present.

Maintenance

ActivityInactive
ResponsivenessSyncing

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    B
    quality
    D
    maintenance
    Enables SSH connectivity and remote command execution on servers, allowing users to test connections and run commands remotely with support for both local networks and public servers.
    2
    24
    1
    ISC
  • A
    license
    A
    quality
    D
    maintenance
    Enables secure SSH connections to multiple remote servers with support for command execution, file transfers (SFTP), directory listing, and both password and key-based authentication.
    7
    MIT
  • A
    license
    Not graded
    quality
    C
    maintenance
    Enables remote execution of Linux commands via SSH, supporting system monitoring, file operations, and secure authentication with configurable safety controls.
    4
    MIT

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/samdoran/mcp_linux_ssh'

If you have feedback or need assistance with the MCP directory API, please join our Discord server