mysql-mcp
mysql-mcp
Ein leichtgewichtiger MCP-Server, der sicheren, schreibgeschützten Zugriff auf MySQL-Datenbanken bietet.
Funktionen
Multi-Datenbank — Verbindung zu mehreren MySQL-Instanzen herstellen, spontan zwischen ihnen wechseln
Schreibgeschützt — Schreibvorgänge (
INSERT,UPDATE,DELETE,DROPusw.) werden blockiertLazy Connections — Pools werden bei der ersten Verwendung erstellt, nicht beim Start
MCP-nativ — basiert auf
@modelcontextprotocol/sdk, funktioniert mit jedem MCP-Client
Related MCP server: mcp-database
Einrichtung
Erstellen Sie eine JSON-Konfigurationsdatei mit Ihren Datenbankverbindungen:
{
"my-db": {
"host": "db.example.com",
"port": 3306,
"user": "readonly",
"password": "secret",
"database": "mydb",
"environment": "production",
"ssl": false
}
}Setzen Sie die Umgebungsvariable
MYSQL_DATABASES_CONFIG, die auf diese Datei verweist.Starten Sie den Server:
npx tsx index.tsTools
Tool | Beschreibung |
| Alle konfigurierten Datenbanken und die aktive auflisten |
| Die aktive Datenbankverbindung wechseln |
| Eine schreibgeschützte SQL-Abfrage ausführen |
MCP-Client-Konfiguration
{
"mcpServers": {
"mysql": {
"command": "npx",
"args": ["tsx", "/path/to/mysql-mcp/index.ts"],
"env": {
"MYSQL_DATABASES_CONFIG": "/path/to/databases.json"
}
}
}
}Lizenz
MIT
This server cannot be deployed
Maintenance
Related MCP Connectors
An MCP server that provides read access to your cloud storage providers, bank accounts and more.
Read-only MCP server for The Quiet Protocol's engines, benchmarks, proof, and business data.
Read-only MCP server for ClassQuill, a tutoring-business-management platform.
MCP server for querying and analyzing data from ad platforms, analytics tools, and spreadsheets
Related MCP Servers
- AlicenseAqualityDmaintenanceAn MCP server that provides read-only access to MySQL databases.4317 npm72MIT
- AlicenseAqualityCmaintenanceRead-only MySQL/MariaDB MCP server for running SELECT queries safely, with automatic read-only enforcement and query limits.36 npmMIT
- AlicenseNot gradedqualityDmaintenanceA readonly MCP server for MySQL databases that ensures safety by whitelisting only SELECT, SHOW, DESCRIBE, and EXPLAIN statements, with table blacklist support and configurable limits.MIT
- AlicenseNot gradedqualityDmaintenanceA secure, read-only MySQL database proxy using MCP protocol, enabling SQL queries and table inspections via HTTP.10 npm1MIT