Cover image
Try Now
2025-04-14

servidor MCP para bases de datos

3 years

Works with Finder

0

Github Watches

0

Github Forks

0

Github Stars

Database MCP Servers Setup Guide

This guide explains how to set up Model Context Protocol (MCP) servers for various AWS database services to use with Amazon Bedrock models.

Supported Databases

  • Amazon RDS MySQL: SQL database service
  • Amazon DocumentDB: MongoDB-compatible document database
  • Amazon DynamoDB: NoSQL key-value and document database
  • Amazon Redshift: Data warehouse service
  • Amazon ElastiCache Redis: In-memory data store

Prerequisites

Before setting up the MCP servers, ensure you have:

  1. Access to AWS services and appropriate permissions
  2. Database instances already created and accessible
  3. Node.js and npm installed
  4. Python 3 installed
  5. Git installed
  6. Docker installed (optional, for containerized MCP servers)

You can check and install prerequisites using:

chmod +x check_prerequisites.sh
./check_prerequisites.sh

Setup Process

1. Configure Database Credentials

Create a credentials file with your database connection information:

cp db_credentials_template.sh set_db_credentials.sh

Edit set_db_credentials.sh and fill in your actual database credentials.

2. Validate Database Connections

Before setting up the MCP servers, validate that your database connections work:

chmod +x validate_db_connections.sh
source ./set_db_credentials.sh
./validate_db_connections.sh

This script will test connections to all configured databases and report any issues.

3. Set Up MCP Servers

Run the secure setup script to install and configure all database MCP servers:

chmod +x setup_db_mcp_servers_secure.sh
./setup_db_mcp_servers_secure.sh

This script will:

  • Clone necessary repositories
  • Build required components
  • Update the MCP configuration
  • Restart the MCP services

4. Test MCP Servers

After setup, test that all MCP servers are working correctly:

chmod +x test_mcp_servers.sh
./test_mcp_servers.sh

Usage Examples

Once the MCP servers are set up, you can use them with Amazon Bedrock models through the MCP framework. Here are some example prompts:

MySQL

Show me all tables in the MySQL database.
Run a query to select the first 10 rows from the customers table.
What are the column names and data types in the orders table?

MongoDB/DocumentDB

List all collections in the MongoDB database.
Find documents in the users collection where age is greater than 30.
Show me the schema of the products collection.

DynamoDB

List all tables in DynamoDB.
Get items from the Orders table where CustomerId equals 'CUST001'.
What are the primary key attributes for the Products table?

Redshift

Show me all tables in the Redshift database.
Run a query to analyze sales data by region.
Explain the schema of the customer_transactions table.

Redis

Get all keys in Redis.
What is the value of the key 'session:user123'?
Show me all members of the set 'active_users'.

Security Considerations

  • Never commit credentials to version control
  • Consider using AWS Secrets Manager or Parameter Store for credential management
  • Use IAM roles instead of access keys when possible
  • Implement least privilege access for database users
  • Set appropriate read/write permissions in MCP server configurations

Troubleshooting

If you encounter issues:

  1. Check the logs in the logs directory
  2. Verify database connectivity using the validation script
  3. Ensure all required environment variables are set
  4. Check that the MCP service is running (http://127.0.0.1:7002)
  5. Verify that the Chatbot UI is accessible (http://localhost:8502)

Additional Resources

相关推荐

  • av
  • Ejecute sin esfuerzo LLM Backends, API, frontends y servicios con un solo comando.

  • 1Panel-dev
  • 🔥 1Panel proporciona una interfaz web intuitiva y un servidor MCP para administrar sitios web, archivos, contenedores, bases de datos y LLM en un servidor de Linux.

  • WangRongsheng
  • 🧑‍🚀 全世界最好的 llM 资料总结(数据处理、模型训练、模型部署、 O1 模型、 MCP 、小语言模型、视觉语言模型) | Resumen de los mejores recursos del mundo.

  • rulego
  • ⛓️Rulego es un marco de motor de regla de orquestación de componentes de alta generación de alto rendimiento, de alto rendimiento y de alto rendimiento para GO.

  • sigoden
  • Cree fácilmente herramientas y agentes de LLM utilizando funciones Plain Bash/JavaScript/Python.

  • hkr04
  • SDK liviano C ++ MCP (Protocolo de contexto del modelo)

  • RockChinQ
  • 😎简单易用、🧩丰富生态 - 大模型原生即时通信机器人平台 | 适配 Qq / 微信(企业微信、个人微信) / 飞书 / 钉钉 / Discord / Telegram / Slack 等平台 | 支持 Chatgpt 、 Deepseek 、 DiFy 、 Claude 、 Gemini 、 Xai 、 PPIO 、 Ollama 、 LM Studio 、阿里云百炼、火山方舟、 Siliconflow 、 Qwen 、 Moonshot 、 Chatglm 、 SillyTraven 、 MCP 等 LLM 的机器人 / Agente | Plataforma de bots de mensajería instantánea basada en LLM, admite Discord, Telegram, WeChat, Lark, Dingtalk, QQ, Slack

  • dmayboroda
  • Trapo conversacional local con contenedores configurables

  • modelscope
  • Iniciar aplicaciones de múltiples agentes empoderadas con Building LLM de manera más fácil.

  • evilsocket
  • El kit de desarrollo de agentes simples.

    Reviews

    2.6 (5)
    Avatar
    user_mGxEahpE
    2025-04-24

    As a dedicated mcpseverdbs user, I must say it has significantly streamlined my server database management. The interface is intuitive, and the support from the creator, milan9527, is outstanding. The overall performance and reliability have exceeded my expectations. Highly recommended for anyone looking to simplify their server database tasks!

    Avatar
    user_B5N2gbPZ
    2025-04-24

    As a devoted user of mcp applications, mcpseverdbs by milan9527 has impressed me greatly. The product is reliable and efficient, streamlining server database management with ease. With a user-friendly interface, it ensures a smooth experience, even for those new to such tools. Highly recommended for anyone looking to enhance their server management capabilities!

    Avatar
    user_YwyIFAZV
    2025-04-24

    As a dedicated user of mcpserverdbs, I must say this product by milan9527 has significantly improved my workflow. Its seamless integration and user-friendly interface make managing server databases a breeze. Highly recommend it for anyone looking to streamline their database management tasks.

    Avatar
    user_yN8GylEj
    2025-04-24

    I've been using mcpseverdbs for a while, and I must say it's fantastic! Developed by milan9527, this application offers excellent functionality and a user-friendly interface. It has significantly improved my database management and reduced the time I spend on mundane tasks. Highly recommended!

    Avatar
    user_KajLd6nd
    2025-04-24

    As a dedicated user of mcpseverdbs, I am thoroughly impressed with its performance and reliability. Created by milan9527, this product excels in seamless integration and user-friendly interface. It has significantly streamlined my database management tasks. Highly recommended for anyone in need of a robust and efficient server database solution!