Skip to content
Mambo edited this page Apr 10, 2025 · 12 revisions

앤트로픽이 2024년 11월에 소개Model Context Protocol(MCP)는 에이전틱 AI를 위한 호출에 사용되는 사실 상 표준.

Requirements

claude_desktop_config.json

C:\Users\Mambo\AppData\Roaming\Claude\calude_desktop_config.json

MCP 서버 설정 트러블슈팅

command not found: /Users/eip/Desktop

  • nvm 을 사용하여 노드 버전을 관리하는 경우 Claude Desktop 에서 사용하는 노드 버전이 다른 문제가 발생함.
  • servers#64를 참고하면 /usr/local/bin/npx-for-mcp 를 만들어서 nvm 으로 설치된 노드 버전을 사용하도록 설정 가능
{
  "mcpServers": {
    "filesystem": {
      "command": "npx-for-mcp",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/Users/USERNAME/Desktop",
        "/Users/USERNAME/Documents",
        "/Users/USERNAME/Downloads"
      ]
    },
  }
}

import: command not found

npx-for-mcp 를 사용했는데 server-redis 에서는 그대로 오류가 발생했음,

/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 1: import: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 2: import: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 3: import: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 4: import: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 5: import: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 6: //: is a directory
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 7: const: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 7: redis://localhost:6379: No such file or directory
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 8: const: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 9: const: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 9: //: is a directory
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 10: const: command not found
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 10: //: is a directory
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 11: //: is a directory
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 12: syntax error near unexpected token `('
/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis: line 12: `const redisClient = createClient({'
{
  "mcpServers": {
    "redis": {
      "command": "/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/node",
      "args": [
        "/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/redis",
        "redis://localhost:6379"
      ]
    }
  }
}

ls: /.nvm/versions/node: No such file or directory

@modelcontextprotocol/server-gdrive의 경우도

ls: /.nvm/versions/node: No such file or directory

ERROR: You must supply a command.

Execute binaries from npm packages.

  npx [options] <command>[@version] [command-arg]...

  npx [options] [-p|--package <package>]... <command> [command-arg]...

  npx [options] -c '<command-string>'

  npx --shell-auto-fallback [shell]


Options:
  --package, -p          Package to be installed.                       [string]
  --cache                Location of the npm cache.                     [string]
  --always-spawn         Always spawn a child process to execute the command.
                                                                       [boolean]
  --no-install           Skip installation if a package is missing.    [boolean]
  --userconfig           Path to user npmrc.                            [string]
  --call, -c             Execute string as if inside `npm run-script`.  [string]
  --shell, -s            Shell to execute the command with, if any.
                                                       [string] [default: false]
  --shell-auto-fallback  Generate shell code to use npx as the "command not
                         found" fallback.
                                   [string] [choices: "", "bash", "fish", "zsh"]
  --ignore-existing      Ignores existing binaries in $PATH, or in the local
                         project. This forces npx to do a temporary install and
                         use the latest version.                       [boolean]
  --quiet, -q            Suppress output from npx itself. Subcommands will not
                         be affected.                                  [boolean]
  --npm                  npm binary to use for internal operations.
                                                              [string] [default:
  "/Users/USERNAME/.nvm/versions/node/v12.22.12/lib/node_modules/npm/bin/npm-cli.js"]
  --node-arg, -n         Extra node argument when calling a node binary.[string]
  --version, -v          Show version number                           [boolean]
  --help, -h             Show help                                     [boolean]

For the full documentation, see the manual page for npx(1).
{
  "mcpServers": {
    "gdrive": {
      "command": "/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/node",
      "args": [
        "/Users/USERNAME/.nvm/versions/node/v22.14.0/bin/mcp-server-gdrive"
      ],
      "env": {
        "GDRIVE_CREDENTIALS_PATH": "/Users/USERNAME/servers/.gdrive-server-credentials.json"
      }
    }
  }
}

ERROR: You must supply a command.

2025-04-09T04:52:11.180Z [sequential-thinking] [info] Initializing server...
2025-04-09T04:52:11.216Z [sequential-thinking] [info] Server started and connected successfully
2025-04-09T04:52:11.217Z [sequential-thinking] [info] Message from client: {"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"claude-ai","version":"0.1.0"}},"jsonrpc":"2.0","id":0}

ERROR: You must supply a command.

Execute binaries from npm packages.

  npx [options] <command>[@version] [command-arg]...

  npx [options] [-p|--package <package>]... <command> [command-arg]...

  npx [options] -c '<command-string>'

  npx --shell-auto-fallback [shell]


Options:
  --package, -p          Package to be installed.                       [string]
  --cache                Location of the npm cache.                     [string]
  --always-spawn         Always spawn a child process to execute the command.
                                                                       [boolean]
  --no-install           Skip installation if a package is missing.    [boolean]
  --userconfig           Path to user npmrc.                            [string]
  --call, -c             Execute string as if inside `npm run-script`.  [string]
  --shell, -s            Shell to execute the command with, if any.
                                                       [string] [default: false]
  --shell-auto-fallback  Generate shell code to use npx as the "command not
                         found" fallback.
                                   [string] [choices: "", "bash", "fish", "zsh"]
  --ignore-existing      Ignores existing binaries in $PATH, or in the local
                         project. This forces npx to do a temporary install and
                         use the latest version.                       [boolean]
  --quiet, -q            Suppress output from npx itself. Subcommands will not
                         be affected.                                  [boolean]
  --npm                  npm binary to use for internal operations.
                                                              [string] [default:
  "/Users/USERNAME/.nvm/versions/node/v12.22.12/lib/node_modules/npm/bin/npm-cli.js"]
  --node-arg, -n         Extra node argument when calling a node binary.[string]
  --version, -v          Show version number                           [boolean]
  --help, -h             Show help                                     [boolean]

For the full documentation, see the manual page for npx(1).
2025-04-09T04:52:11.741Z [sequential-thinking] [info] Server transport closed
2025-04-09T04:52:11.741Z [sequential-thinking] [info] Client transport closed
2025-04-09T04:52:11.742Z [sequential-thinking] [info] Server transport closed unexpectedly, this is likely due to the process exiting early. If you are developing this MCP server you can add output to stderr (i.e. `console.error('...')` in JavaScript, `print('...', file=sys.stderr)` in python) and it will appear in this log.
2025-04-09T04:52:11.742Z [sequential-thinking] [error] Server disconnected. For troubleshooting guidance, please visit our [debugging documentation](https://modelcontextprotocol.io/docs/tools/debugging) {"context":"connection"}

spawn uvx ENOENT

Model Context Protocol servers 중 time, git, sqlite, fetch 등은 Python MCP SDK로 작성되어있어 uv 패키지 매니저가 설치되어있어야 한다. 맥 환경에 설치된 uv의 경로가 /Users/USERNAME/.local/bin에 있다면 Claude Desktop 에서 바라보지 못할 수 있으므로 전체 경로를 지정해주거나 brew install uv 로 설치해도 된다.

2025-04-09T04:55:27.164Z [time] [info] Initializing server...
2025-04-09T04:55:27.186Z [time] [error] spawn uvx ENOENT {"context":"connection","stack":"Error: spawn uvx ENOENT\n    at ChildProcess._handle.onexit (node:internal/child_process:285:19)\n    at onErrorNT (node:internal/child_process:483:16)\n    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)"}
2025-04-09T04:55:27.187Z [time] [error] spawn uvx ENOENT {"stack":"Error: spawn uvx ENOENT\n    at ChildProcess._handle.onexit (node:internal/child_process:285:19)\n    at onErrorNT (node:internal/child_process:483:16)\n    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)"}
2025-04-09T04:55:27.188Z [time] [info] Server transport closed
2025-04-09T04:55:27.188Z [time] [info] Client transport closed
2025-04-09T04:55:27.189Z [time] [info] Server transport closed unexpectedly, this is likely due to the process exiting early. If you are developing this MCP server you can add output to stderr (i.e. `console.error('...')` in JavaScript, `print('...', file=sys.stderr)` in python) and it will appear in this log.
2025-04-09T04:55:27.189Z [time] [error] Server disconnected. For troubleshooting guidance, please visit our [debugging documentation](https://modelcontextprotocol.io/docs/tools/debugging) {"context":"connection"}
{
  "mcpServers": {
    "time": {
      "command": "/Users/USERNAME/.local/bin/uvx",
      "args": ["mcp-server-time", "--local-timezone=Asia/Seoul"]
    }
  }
}

Github MCP failed with PAT

ref: github-mcp-server#153

위 이슈처럼 Fine-grained PAT를 사용하는 경우 전체 액세스 권한을 부여해도 조직 리파지토리에 접근할 수 없었다. 아래 이미지와 같이 조직에서 액세스 토큰 사용에 대한 권한을 제한된 부분은 없는 상태이다.

image

Clone this wiki locally