Skip to main content
Glama
kevinwatt

MySQL MCP Server

by kevinwatt

MySQL MCP 서버

LLM에 대한 안전한 데이터베이스 액세스 기능을 제공하는 MySQL 데이터베이스와 통합된 MCP 서버 구현입니다.

특징

  • 읽기 작업

    • 읽기 전용 SELECT 쿼리 실행

    • 모든 데이터베이스 테이블 나열

    • 테이블 구조 표시

    • 스키마 정보 보기

  • 쓰기 작업

    • 트랜잭션 지원을 통해 INSERT/UPDATE/DELETE 실행

    • 데이터 안전을 위한 매개변수화된 쿼리

    • 영향을 받은 행과 삽입 ID를 반환합니다.

  • 보안

    • SELECT 쿼리에 대한 읽기 전용 트랜잭션 모드

    • 쿼리 길이 및 결과 크기 제한

    • 성능 모니터링 및 로깅

    • 자동 거래 처리

Related MCP server: DatabaseMCP

설치

지엑스피1

Dive Desktop 사용

  1. Dive Desktop에서 "+ MCP 서버 추가"를 클릭하세요.

  2. 다음 구성을 복사하여 붙여넣으세요.

{
  "mcpServers": {
    "mysql": {
      "command": "npx",
      "args": [
        "-y",
        "@kevinwatt/mysql-mcp"
      ],
      "env": {
        "MYSQL_HOST": "127.0.0.1",
        "MYSQL_PORT": "3306",
        "MYSQL_USER": "root",
        "MYSQL_PASS": "",
        "MYSQL_DB": "your_database"
      }
    }
  }
}
  1. "저장"을 클릭하여 MCP 서버를 설치하세요.

도구 문서

  • mysql_쿼리

    • 읽기 전용 SELECT 쿼리 실행

    • 입력:

      • sql (문자열): 실행할 SQL SELECT 쿼리

    • 제한:

      • 최대 쿼리 길이: 4096자

      • 최대 결과 행: 1000

      • 쿼리 시간 초과: 30초

  • mysql_execute

    • 데이터 수정 작업 실행

    • 입력:

      • sql (문자열): SQL 명령문(INSERT/UPDATE/DELETE)

      • params (배열, 선택 사항): SQL 문에 대한 매개변수

    • 특징:

      • 영향을 받은 행 수를 반환합니다.

      • 마지막 삽입 ID를 반환합니다.

      • 자동 거래 처리

  • 리스트_테이블

    • 현재 데이터베이스의 모든 테이블 나열

    • 입력이 필요하지 않습니다

  • 설명_테이블

    • 테이블 구조 표시

    • 입력:

      • table (문자열): 설명할 테이블 이름

사용 예

LLM에 다음을 요청하세요.

"Show me all tables in the database"
"Describe the structure of users table"
"Select all active users from the database"
"Insert a new record into orders table"

수동 시작

필요한 경우 서버를 수동으로 시작합니다.

npx @kevinwatt/mysql-mcp

요구 사항

  • 노드.js 18+

  • MySQL 서버

  • MCP 호환 LLM 서비스

특허

MIT

작가

더웨이 옌

키워드

  • 엠씨피

  • MySQL

  • 데이터 베이스

  • 잠수

  • LLM

  • 일체 포함

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    A high-performance MCP server that enables AI assistants to safely interact with MySQL databases through secure CRUD operations, schema inspection, and parameterized queries with built-in SQL injection prevention.
    1
    -
  • F
    license
    Not graded
    quality
    B
    maintenance
    An MCP server that enables AI agents to safely explore and interact with MySQL databases through dynamic tool generation from stored procedures. It provides database discovery capabilities and intelligent procedure categorization while enforcing security restrictions to prevent data modification.
    -
  • A
    license
    Not graded
    quality
    D
    maintenance
    A MySQL MCP server for secure database interaction, enabling schema inspection, query execution, and RBAC via AI coding assistants.
    392 npm
    5
    MIT
  • A
    license
    Not graded
    quality
    C
    maintenance
    A secure and efficient MCP server for MySQL database operations, enabling LLMs to execute SQL queries with read-only access by default and optional write permissions.
    3
    MIT