MCP.so
Sign In

MCP Port Cleaner Server

@BrightLin

About MCP Port Cleaner Server

Use this MCP Server when you encounter 'EADDRINUSE' (Address already in use).

Config

Add this server to your MCP-compatible client using the configuration below.

{
  "mcpServers": {
    "port-cleaner": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-server-port-cleaner"
      ]
    }
  }
}

Tools

No tools detected

Fetch the live tool list by running this server in a temporary sandbox using the button above.

Overview

What is MCP Port Cleaner Server?

It is a Node.js server implementing the Model Context Protocol (MCP) for port cleanup operations in development environments. It helps developers find and terminate processes occupying specified ports to resolve conflicts.

How to use MCP Port Cleaner Server?

Install via npx (npx -y mcp-server-port-cleaner) or globally (npm install -g mcp-server-port-cleaner). Configure it as an MCP server in Claude Desktop or Trae.cn using the tool commands port_scan (list processes on a port) and port_clean (terminate processes on a port), both accepting a port integer (1–65535) as input.

Key features of MCP Port Cleaner Server

  • Finds and terminates processes occupying specified ports
  • Scans and lists all processes on a specified port (cross-platform)
  • Safe input validation using Zod schema
  • Detailed error handling and response formatting
  • Standard MCP protocol compliance for tool registration

Use cases of MCP Port Cleaner Server

  • Resolving development environment port conflicts
  • Automating port cleanup in CI/CD pipelines
  • Managing port availability on shared development servers

FAQ from MCP Port Cleaner Server

What tools does MCP Port Cleaner Server provide?

It provides two tools: port_scan to list processes on a port and port_clean to terminate processes on a port.

What platforms are supported?

Linux/Unix and Windows are supported, using platform‑specific commands such as lsof, kill, netstat on Linux/Unix and netstat, tasklist, taskkill on Windows.

What input parameters are required?

Both tools require a port parameter as an integer between 1 and 65535.

How does the termination work?

The cleanup implementation terminates processes with SIGKILL (-9).

Frequently asked questions

What tools does MCP Port Cleaner Server provide?

It provides two tools: `port_scan` to list processes on a port and `port_clean` to terminate processes on a port.

What platforms are supported?

Linux/Unix and Windows are supported, using platform‑specific commands such as `lsof`, `kill`, `netstat` on Linux/Unix and `netstat`, `tasklist`, `taskkill` on Windows.

What input parameters are required?

Both tools require a `port` parameter as an integer between 1 and 65535.

How does the termination work?

The cleanup implementation terminates processes with SIGKILL (-9).

Comments

More Other MCP servers