MCP SFTP Orchestrator
The MCP SFTP Orchestrator is a Model Context Protocol server for orchestrating remote SSH/SFTP tasks, server management, and system monitoring through an LLM-compatible stdio interface.
Core Capabilities:
Server Management: Add, list, and remove server configurations with SSH key or password authentication and secure credential storage.
SSH Command Execution: Execute simple, interactive, or sequential commands with auto-response to prompts, persistent connection pools, automatic retry, and log streaming (PM2, Docker, tail, journalctl).
SFTP File Transfers: Upload/download files and folders with glob pattern support (
*.txt,**/*.js), multi-file transfers, and automatic parent directory creation.System Monitoring: Check system resources (CPU, RAM, Disk, load average), service status (systemd, Docker, PM2), Fail2Ban information, and perform HTTP/HTTPS health checks with authentication.
API Management: Configure and manage an API catalog for health monitoring with various authentication methods (API key, Basic Auth, both, or none).
Log Retrieval: Access PM2 application logs, Docker container logs with timestamp/time-range filters, tail remote files, and view MCP system logs with filtering.
Task Queue Management: Persistent, auto-saving queue with hybrid sync/async execution, detailed task history, manual/automatic retry, and comprehensive statistics including success rates and average durations.
System Administration: Monitor SSH connection pool statistics, system diagnostics, and performance metrics with structured error handling and security best practices.
Enables monitoring and retrieval of Docker container logs, including container status checks and log streaming with configurable parameters.
Supports configuration through .env files for managing environment variables and server settings.
Provides SFTP-based file transfer capabilities including upload/download of files and directories with glob pattern support and automatic parent directory creation.
Enables monitoring and management of NGINX services through systemd service status checks and log retrieval.
Supports installation and execution via npm/npx package manager for streamlined deployment.
Provides dedicated tools for retrieving PM2 process logs, monitoring application status, and managing PM2-controlled services.
Recommended for secure storage and management of secrets and API credentials as part of security best practices.
Uses Zod schema validation for input validation and type safety of tool arguments and configuration.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP SFTP Orchestratorcheck the CPU and memory usage on my production server"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
🚀 MCP Orchestrator — SSH/SFTP Infrastructure Orchestration Server
Version : 11.3.0
License : MIT
Node : >= 18.0.0
A Model Context Protocol (MCP) server that turns any AI agent (Claude, OpenCode, Cursor...) into a full-fledged system administrator. Persistent queue, SSH connection pool, hybrid sync/async execution.
✨ Key Features
63 MCP tools — SSH, SFTP, file ops, monitoring, snapshots, tunnels
Built-in security — Command blocklist, port allowlist, hash protection
Multi-server —
task_exec {alias:["vps1","vps2"]}oralias:"all"}Persistence — tmux + persistent queue = sessions that survive crashes
Snapshots — Deduplicated versioning of your critical files
SSH Tunnels — Local, Remote, SOCKS5 with secured port allowlist
AI Guide — Built-in manual for the agent (section:index/workflows/audit/security)
🇫🇷 Version française : README.fr.md
📦 Installation
Via npx (recommended)
npx @fkom13/mcp-sftp-orchestratorVia git
git clone https://github.com/fkom13/mcp-sftp-orchestrator.git
cd mcp-sftp-orchestrator
npm install
cp .env.example .env
# Edit .env with your pathsRequirements: Node.js >= 18.0.0
Related MCP server: SSH MCP Server
⚙️ Configuration (.env)
All variables are optional. Defaults are designed for standard usage.
Variable | Default | Description |
|
| Data directory (servers.json, apis.json, queue.json) |
|
| Seconds before background execution |
|
| Default SSH timeout (0 = unlimited) |
|
| Interactive command timeout (0 = unlimited) |
|
| Max timeout for |
|
| Max parallel SSH connections per server |
|
| Min pooled connections per server |
|
| Idle connection close delay (ms) |
|
| SSH keepalive interval (ms) |
|
| Max jobs in queue |
|
| Queue disk save interval (ms) |
| (empty) | Restrict file access to these roots (comma-separated). Empty = full access |
|
| Enable detailed debug logs |
🔌 MCP Client Configuration (OpenCode, Claude Desktop, etc.)
{
"mcpServers": {
"orchestrator": {
"command": "node",
"args": ["/path/to/sftp-mcp/server.js"],
"env": {
"MCP_DATA_DIR": "/path/to/sftp-mcp/data"
}
}
}
}🧰 Tool Reference (63 tools)
Help & Diagnostics
Tool | Description |
| Complete guide: tools, env vars, parameter schemas |
| AI manual: workflows, cheatsheet, audit, security |
| Full system diagnostic (queue, pool, servers, APIs) |
Server Management
Tool | Description |
| Add/update a server alias |
| List all configured servers |
| Remove a server alias |
| Fleet-wide overview (roles, services, warnings) |
| Documented server context |
Security (Blocklist)
Tool | Description |
| List blocked commands |
| Add a pattern to blocklist |
| Remove a pattern from blocklist |
Task Execution
Tool | Description |
| SSH one-shot. Supports |
| SSH with interactive prompt handling |
| Sequential SSH commands |
| SFTP transfer. Supports |
| Bulk transfers with glob patterns |
Monitoring
Tool | Description |
| CPU, RAM, Disk metrics |
| systemd, Docker, PM2 status (graceful fallback) |
| Fail2Ban status |
| HTTP health check |
Logs
Tool | Description |
| PM2 logs |
| Docker logs |
| Tail a remote file |
File Operations (Local + Remote)
Tool | Description |
| Read file + SHA-256 hash (edit protection) |
| Create/overwrite with |
| Surgical or full edit + hash protection |
Comparison & Drift Detection
Tool | Description |
| Compare 2 files (local/remote, cross-server) |
| Compare 2 directories |
| Detect drifts across N servers |
Persistent Shell Sessions
Tool | Description |
| Open a persistent shell (cd/env preserved) |
| Execute in an existing session |
| List/close sessions |
tmux (Surviving Terminal Sessions)
Tool | Description |
| Create a persistent tmux session |
| Send a command to a session |
| Read session buffer |
| List/kill sessions |
SSH Tunnels
Tool | Description |
| Local/remote/SOCKS5 tunnel, persistent via tmux |
| List active tunnels |
| Close a tunnel |
| Manage allowed ports |
Snapshots (File Versioning)
Tool | Description |
| Capture file state with deduplication |
| List snapshots |
| Compare 2 snapshots |
| Restore (dryRun by default) |
| Delete + orphan cleanup |
Queue & Monitoring
Tool | Description |
| View all active/pending tasks |
| Task detail by ID |
| Filterable history |
| Retry a failed task |
| Wait for a background task |
| MCP internal logs |
| Queue and SSH pool stats |
API Catalog
Tool | Description |
| API monitoring catalog |
| Health check via SSH + curl |
📖 Usage Examples
Multi-server
# One command, multiple servers
task_exec {alias:["vps1","vps2","vps3"], cmd:"uptime"}
# Entire fleet
task_exec {alias:"all", cmd:"df -h /"}SOCKS5 Proxy Tunnel
tunnel_create {name:"proxy", type:"socks", listen_port:1080, via:"vps_paris"}
# → Browser → SOCKS5 127.0.0.1:1080 → Paris VPSLocal Tunnel (access remote service)
tunnel_create {name:"crm", type:"local", listen_port:8080, target:"127.0.0.1:3100", via:"vps_prod"}
# → http://localhost:8080 → production CRMRemote Tunnel (expose local service)
tunnel_create {name:"dev", type:"remote", listen_port:9090, target:"127.0.0.1:3000", via:"vps", source:"vps_prod", key_path:"/home/user/.ssh/vps.key"}
# → vps_prod:9090 → your local machine:3000Persistent tmux Session
tmux_create {alias:"vps", name:"build", start_cmd:"npm run build"}
tmux_read {alias:"vps", session:"build"}
tmux_kill {alias:"vps", session:"build"}Security Blocklist
# List blocked commands
policy_blocklist_list
# → ["rm -rf /", "mkfs*", ...]
# Conscious bypass
task_exec {alias:"vps", cmd:"rm -rf /tmp/cache", skip_policy:true}Secure File Editing
# Read + hash
file_read {source:{type:"remote", alias:"vps", path:"/etc/nginx/nginx.conf"}}
# → content + hash
# Edit with protection
file_edit {source:{type:"remote", alias:"vps", path:"/etc/nginx/nginx.conf"},
oldString:"worker_connections 768;",
newString:"worker_connections 1024;",
expectedHash:"abc123...",
backup:true}
# Preview without writing
file_edit {source:{type:"remote", alias:"vps", path:"/etc/nginx/nginx.conf"},
oldString:"worker_connections 768;",
newString:"worker_connections 1024;",
dryRun:true}Snapshot Before Risky Changes
# Before
snapshot_create {source:{type:"remote", alias:"vps"}, paths:["/etc/nginx/"], tag:"before-fix"}
# After if something broke
snapshot_restore {snapshotId:"...", target:{type:"remote", alias:"vps"}, dryRun:false, force:true}Multi-server Drift Detection
compare_all_sources {sources:[
{type:"remote", alias:"vps1", path:"/etc/nginx/nginx.conf", label:"prod"},
{type:"remote", alias:"vps2", path:"/etc/nginx/nginx.conf", label:"staging"}
]}📚 AI Built-in Manual (guide)
The orchestrator includes an interactive manual for your AI agent:
guide section:index # Table of contents
guide section:workflows # Copy-paste recipes
guide section:cheatsheet # Tool → usage table
guide section:audit # Full fleet audit in 8 steps
guide section:security # Blocklist + tunnels
guide section:pitfalls # Common mistakes🏗️ Architecture
MCP Client (stdio)
│
server.js ─── 63 MCP tools registered
│
├── queue.js ─────── Persistent job queue (JSON + backup)
├── ssh.js ───────── SSH execution (pool + dedicated connections)
├── sftp.js ──────── SFTP transfers (upload/download/multi)
├── sshPool.js ───── Persistent SSH connection pool
├── servers.js ───── CRUD server aliases
├── apis.js ──────── CRUD API catalog
├── history.js ───── Task history
├── config.js ────── Centralized configuration
├── utils.js ─────── Utilities (escapeShellArg)
├── fileOps.js ───── File operations (read/write/edit)
├── diffEngine.js ── Diff engine (files/dirs/sources)
├── compareEngine.js ─ Multi-source comparison
├── diffFormatter.js ─ Diff formatting
├── sourceAdapter.js ─ Local/remote abstraction
├── shellSessions.js ─ Persistent shell sessions
├── snapshotManager.js ─ Versioned snapshots
├── notes.js ──────── Documented server context
├── policies.js ──── Command blocklist
├── tunnels.js ────── SSH tunnels (local/remote/SOCKS)
├── guide.js ──────── AI built-in manual
└── diagnose.js ───── DiagnosticsJob Lifecycle
pending → running → completed / failed
↓ (on restart)
crashed → retry → pending🔒 Security
Command Blocklist :
rm -rf /,mkfs*, fork bombs, and other destructive commands are blocked by defaultConscious bypass :
skip_policy: trueto force executionTunnel port allowlist : only explicitly allowed ports can be used
File access restriction :
MCP_ALLOWED_ROOTSenv var to limit file operations to specific directoriesescapeShellArg(): all URLs and paths are escaped before being passed to curl/shellPlaintext secret detection : warning on startup if passwords/API keys are in plaintext
Pre-modification snapshots :
backup:trueon file_edit/file_write for instant rollbackRecommendation : use SSH keys (not passwords), store secrets in Vaultwarden
🧪 Tests
node diagnose.js # Full diagnostic
node test_mcp.js # MCP smoke test
node test_features.js # Unit tests (queue, pool, glob, prompts, crash)🛣️ Roadmap
Version | Changes |
10.0.0 | New tools: file_read/write/edit, diff, snapshots, shell, notes |
10.4.0 | server_to_server, help with schemas, audit guide |
11.0.0 | Command Blocklist, Multi-host ( |
11.2.0 | SSH Tunnels (local/remote/SOCKS5), allowlist, ssh2 stderr fix |
11.3.0 | AllowedRoots ( |
12.0.0 (planned) | Auto key setup for tunnels, webhooks, static dashboard |
📄 License
MIT — Copyright (c) 2025-2026 Franck (fkom13)
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables secure SSH connections to multiple remote servers with support for command execution, file transfers (SFTP), directory listing, and both password and key-based authentication.7MIT
- AlicenseAqualityDmaintenanceEnables remote server management through SSH and SFTP, supporting command execution, file transfers, and interactive shell sessions. It allows for multiple concurrent connections using either password or SSH key authentication.11103MIT
- AlicenseAqualityCmaintenanceEnables AI assistants to manage remote servers via SSH with agentless command execution, file operations, and service management.9MIT
- Alicense-qualityBmaintenanceEnables AI assistants to manage remote servers via SSH with 14 commands for execution, file transfer, auditing, and monitoring.271MIT
Related MCP Connectors
Let AI operate servers without SSH. Choose actions, approve risky changes, and audit every step.
Operate your Linux servers from your LLM. Every action runs through an auditable allowlist.
Uptime, API and server monitoring with outages, reporting, on-call and status pages.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/fkom13/mcp-sftp-orchestrator'
If you have feedback or need assistance with the MCP directory API, please join our Discord server