POX SDN Controller MCP server

Bridges to the POX SDN controller, enabling network topology management and configuration of OpenFlow-based networks through specialized tools for datapath management, flow statistics, and table configuration.
Back to servers
Provider
David Lin
Release date
Mar 23, 2025
Language
Python
Stats
1 star

This MCP server implementation provides network control and management capabilities through the POX SDN controller. It enables Python-based network programming, OpenFlow device management, and automated network analysis through POX's modular architecture, making it ideal for educational environments, network prototyping, and SDN research.

Server Resources

The POX MCP server exposes two dynamic resources:

  • pox://network-config: A comprehensive POX controller configuration memo that tracks active POX components, records network topology and flow rules, and maintains discovered network insights.

  • pox://topology: Real-time network topology view showing active OpenFlow datapaths (switches), host locations and connections, and link status with port mappings.

Available Prompts

pox-network-manager

Interactive prompt for POX controller management:

  • Required argument: topic - The network control aspect to focus on
  • Helps configure POX components and modules
  • Guides through network policy implementation
  • Integrates with network configuration memo

simple-hub

Basic L2 hub implementation using POX:

  • Required argument: dpid - The datapath identifier
  • Demonstrates POX's event-driven programming
  • Shows basic packet handling and flooding
  • Explains POX's core mechanisms

learning-switch

L2 learning switch implementation:

  • Required argument: dpid - The datapath identifier
  • Showcases POX's table management
  • Implements MAC learning and forwarding
  • Demonstrates POX's packet handling capabilities

Server Tools

Datapath Management Tools

get_switches

Lists all connected OpenFlow datapaths:

  • No input required
  • Returns: Array of active POX-controlled switches with connection status and capabilities

get_switch_desc

Get detailed datapath information:

  • Input:
    • dpid (string): Datapath identifier
  • Returns: POX-managed switch details and features

Flow Management Tools

get_flow_stats

Retrieve POX flow statistics:

  • Input:
    • dpid (string): Datapath identifier
    • match (object, optional): POX match structure
    • table_id (string, optional): OpenFlow table ID
    • out_port (string, optional): Output port filter
  • Returns: POX flow statistics including packet counts

set_table

Configure POX flow tables:

  • Input:
    • dpid (string): Datapath identifier
    • flows (array): POX flow specifications
  • Returns: Flow table update confirmation

Analysis Tools

append_insight

Add network insights to POX configuration memo:

  • Input:
    • insight (string): Network observation or analysis
  • Returns: Insight addition confirmation and updates the pox://network-config resource

Installation and Setup

To set up the POX MCP server with Claude Desktop, use the following configuration:

UV Configuration

{
  "mcpServers": {
    "pox": {
      "command": "uv",
      "args": [
        "--directory",
        "parent_of_servers_repo/servers/src/mcp_server_pox",
        "run",
        "server.py"
      ],
      "env": {
        "POX_SERVER_URL": "http://localhost:8000"
      }
    }
  }
}

Make sure to replace parent_of_servers_repo with the appropriate path to your server repository. The server will be accessible at the URL specified in the POX_SERVER_URL environment variable, which is set to http://localhost:8000 by default.

How to add this MCP server to Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "cursor-rules-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "cursor-rules-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later