MCP server error in Windsurf #mcp
Can't use the MCP server. Using the code provided below:
"}, "context7": { "command": "npx", "args": ["-y", "@upstash/context7-mcp@latest"] }"
the error is:
"Error: failed to initialize server: <truncated 3 bytes> error code EEXIST npm error syscall rename npm error path /Users/csfalcao/.npm/_cacache/tmp/9ea4a422 npm error dest /Users/csfalcao/.npm/_cacache/content-v2/sha512/02/d7/e8d783a26d2bf9c00a7855636c15813501c850453bfd701196113e296561f362c845492f4d408e88e7badd2a7f5cae859531b6056cb849fb226f9992081f npm error errno -13 npm error EACCES: permission denied, rename '/Users/csfalcao/.npm/_cacache/tmp/9ea4a422' -> '/Users/csfalcao/.npm/_cacache/content-v2/sha512/02/d7/e8d783a26d2bf9c00a7855636c15813501c850453bfd701196113e296561f362c845492f4d408e88e7badd2a7f5cae859531b6056cb849fb226f9992081f' npm error File exists: /Users/csfalcao/.npm/_cacache/content-v2/sha512/02/d7/e8d783a26d2bf9c00a7855636c15813501c850453bfd701196113e296561f362c845492f4d408e88e7badd2a7f5cae859531b6056cb849fb226f9992081f npm error Remove the existing file and try again, or run npm npm error with --force to overwrite files recklessly. npm error A complete log of this run can be found in: /Users/csfalcao/.npm/_logs/2025-05-18T01_12_44_866Z-debug-0.log: server terminated. Check your configuration."
Other MCP servers are ok.
I copied the code here https://github.com/upstash/context7/blob/master/README.md#install-in-windsurf to the map_config.json file and clicked Refresh and the error message above in red is displayed.
Using Windsurf latest version in macOS latest version.
Tried Environment Variables, ERR_MODULE_NOT_FOUND, ESM Resolution Issues, TLS/Certificate Issues and MCP Client Errors with no success
Hi,
Thanks for reporting this! The error you're encountering:
EACCES: permission denied, rename '.../tmp/...' -> '.../content-v2/...'
usually occurs due to a permission issue or a conflict with an existing file in the npm cache.
How to Fix
Try the following steps:
-
Clean the npm cache:
npm cache clean --force -
(Optional) Manually delete the conflicting file (if the error persists):
rm /Users/csfalcao/.npm/_cacache/content-v2/sha512/02/d7/... -
Ensure you own the
.npmdirectory:sudo chown -R $(whoami) ~/.npm -
Retry your command with
--forceif needed:npm install --force
Let me know if the issue persists after trying these steps
After testing the recommended fix, it didn't work (0 available MCP server) but I discovered Windsurf Version: 1.9.2 has discontinued the MCP server list panel so there's no way to see the error message now.
Could you try with Smithery please
Closing this for now, let us know if you encounter more issues