
jamesjohnsdev/postgresql-mcp-server
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
jamesjohnsdev/postgresql-mcp-server は [https://github.com/jamesjohnsdev/postgresql-mcp-server.] からインポートされた MCP サーバーの候補です
概要
jamesjohnsdev/postgresql-mcp-server は [https://github.com/jamesjohnsdev/postgresql-mcp-server.] からインポートされた MCP サーバーの候補です
概要(AI 翻訳)
PostgreSQL データベース管理機能を提供するモデルコンテキストプロトコル(MCP)サーバー。 このサーバーは、既存のPostgreSQLのセットアップを分析し、実装ガイダンスを提供し、データベースの問題のデバッグを支援します。
##特徴
##1. データベース解析([analyze_database)
PostgreSQL データベースの構成とパフォーマンスメトリックの分析:
- 構成解析
- 性能メトリック
- セキュリティ評価
- 最適化のための推奨事項
##2. セットアップ手順(get_setup_instructions)
ステップバイステップPostgreSQLのインストールと設定ガイダンスを提供します。
- プラットフォーム固有のインストール手順
- 構成の推奨事項
- セキュリティのベストプラクティス
- インストール後のタスク
##3. データベースのデバッグ ([[[T2])]) 一般的なPostgreSQLの問題のデバッグ:
- 接続の問題
- パフォーマンスボトルネック
- 衝突をロックする
- レプリケーションの状態
前提条件
- Node.js >= 18.0.0
- PostgreSQLサーバー(対象データベース操作用)
- 対象となるPostgreSQLインスタンスへのネットワークアクセス
インストール
##Smitheryでインストールする
PostgreSQL MCP Server を、Smithery 経由で自動的に Claude デスクトップにインストールするには:
手動インストール
- リポジトリのクローン化
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
PostgreSQL MCP Server
A Model Context Protocol (MCP) server that provides PostgreSQL database management capabilities. This server assists with analyzing existing PostgreSQL setups, providing implementation guidance, and debugging database issues.
Features
1. Database Analysis (analyze_database)
Analyzes PostgreSQL database configuration and performance metrics:
- Configuration analysis
- Performance metrics
- Security assessment
- Recommendations for optimization
// Example usage
{
"connectionString": "postgresql://user:password@localhost:5432/dbname",
"analysisType": "performance" // Optional: "configuration" | "performance" | "security"
}
2. Setup Instructions (get_setup_instructions)
Provides step-by-step PostgreSQL installation and configuration guidance:
- Platform-specific installation steps
- Configuration recommendations
- Security best practices
- Post-installation tasks
// Example usage
{
"platform": "linux", // Required: "linux" | "macos" | "windows"
"version": "15", // Optional: PostgreSQL version
"useCase": "production" // Optional: "development" | "production"
}
3. Database Debugging (debug_database)
Debug common PostgreSQL issues:
- Connection problems
- Performance bottlenecks
- Lock conflicts
- Replication status
// Example usage
{
"connectionString": "postgresql://user:password@localhost:5432/dbname",
"issue": "performance", // Required: "connection" | "performance" | "locks" | "replication"
"logLevel": "debug" // Optional: "info" | "debug" | "trace"
}
Prerequisites
- Node.js >= 18.0.0
- PostgreSQL server (for target database operations)
- Network access to target PostgreSQL instances
Installation
Installing via Smithery
To install PostgreSQL MCP Server for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install @nahmanmate/postgresql-mcp-server --client claude
Manual Installation
- Clone the repository
- Install dependencies:
npm install - Build the server:
npm run build - Add to MCP settings file:
{ "mcpServers": { "postgresql-mcp": { "command": "node", "args": ["/path/to/postgresql-mcp-server/build/index.js"], "disabled": false, "alwaysAllow": [] } } }
Development
npm run dev- Start development server with hot reloadnpm run lint- Run ESLintnpm test- Run tests
Security Considerations
- Connection Security
- Uses connection pooling
インストール
npx -y @smithery/cli install @nahmanmate/postgresql-mcp-server --client claude設定
{
"mcpServers": {
"postgresql-mcp": {
"command": "node",
"args": ["/path/to/postgresql-mcp-server/build/index.js"],
"disabled": false,
"alwaysAllow": []
}
}
}