Token导航 LogoToken导航TokenDH.com
mcpseverdbs (Milan9527) logo
数据服务stdio官方级别未说明来源级核验

mcpseverdbs (Milan9527)

MCP Server

该工具用于为多种AWS数据库服务设置模型上下文协议(MCP)服务器,以便与Amazon Bedrock模型一起使用。

工具数

0

提示词数

0

GitHub Stars

1

资源数

0
数据库连接Python数据分析

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

milan9527

提供方

milan9527

最后核验

2026/5/17 20:52

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

数据库MCP服务器设置指南

本指南解释了如何为各种AWS数据库服务设置模型上下文协议(MCP)服务器,以与Amazon Bedrock模型一起使用。

支持的数据库

  • 亚马逊RDS MySQL:SQL数据库服务
  • 亚马逊文档数据库:MongoDB兼容文档数据库
  • 亚马逊DynamoDB:NoSQL键值和文档数据库
  • 亚马逊红移:数据仓库服务
  • 亚马逊ElastiCache Redis:内存数据存储

先决条件

在设置MCP服务器之前,请确保:

  1. 访问AWS服务和适当权限
  2. 已创建并可访问的数据库实例
  3. 已安装Node.js和npm
  4. Python 3已安装
  5. Git已安装
  6. 已安装Docker(可选,适用于容器化MCP服务器)

您可以通过以下方式检查并安装必备组件:

chmod +x check_prerequisites.sh
./check_prerequisites.sh

设置过程

1.配置数据库凭据

使用数据库连接信息创建凭据文件:

cp db_credentials_template.sh set_db_credentials.sh

编辑 set_db_credentials.sh 并填写您的实际数据库凭据。

2.验证数据库连接

在设置MCP服务器之前,请验证您的数据库连接是否正常工作:

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

此脚本将测试与所有已配置数据库的连接,并报告任何问题。

3.设置MCP服务器

运行安全安装脚本以安装和配置所有数据库MCP服务器:

chmod +x setup_db_mcp_servers_secure.sh
./setup_db_mcp_servers_secure.sh

此脚本将:

  • 克隆必要的存储库
  • 构建所需组件
  • 更新MCP配置
  • 重新启动MCP服务

4.测试MCP服务器

设置后,测试所有MCP服务器是否正常工作:

chmod +x test_mcp_servers.sh
./test_mcp_servers.sh

使用示例

设置好MCP服务器后,您可以通过MCP框架将其与Amazon Bedrock模型一起使用。以下是一些示例提示:

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/文档数据库

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?

红移

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.

瑞迪斯

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

安全考虑

  • 从不将凭据提交到版本控制
  • 考虑使用AWS Secrets Manager或参数存储进行凭据管理
  • 尽可能使用IAM角色而不是访问密钥
  • 为数据库用户实现最低权限访问
  • 在MCP服务器配置中设置适当的读/写权限

故障排除

如果您遇到问题:

  1. 检查日志 logs 目录
  2. 使用验证脚本验证数据库连接
  3. 确保设置了所有必需的环境变量
  4. 检查MCP服务是否正在运行(http://127.0.0.1:7002)
  5. 验证聊天机器人UI是否可访问(http://localhost:8502)

额外资源

目录标签

目录标签

数据库连接Python数据分析数据库管理本地部署AWS服务MCP协议自动化配置

接入字段

传输方式(transport,传输协议)

stdio

鉴权方式(authType,认证方式)

session

工具数量(toolCount,工具数)

0

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

stdiosession部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP