Remote server access causes high memory usage and system freeze

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

My server has 2 cores and 4 GB of RAM. I’ve only configured a /.cursorignore file — I’m not sure what step I’m missing, but the high memory usage issue still isn’t resolved. This is a recurrence after I reinstalled the OS, and I can no longer remember what I did to fix it the first time. Could it be that I’m missing a step in the Ctrl+Shift+P settings?

/proc/
/sys/
/dev/
/run/
/tmp/
/var/lib/docker/
/var/lib/containerd/
/var/cache/
/root/.cache/
/root/.cursor-server/
/root/.hermes/sessions/
**/node_modules/
**/.git/objects/

Steps to Reproduce

Accessing a remote server via SSH for coding work

Screenshots / Screen Recordings

Operating System

Windows 10/11

Version Information

Version: 3.25.6 (user setup)
VS Code Extension API: 1.128.0
Commit: f0df777c412b670d09e3eaf214967d779e67c080
Date: 2026-10-14T22:46:28.448Z
Layout: IDE
Build Type: Stable
Release Track: Default
Electron: 42.10.0
Chromium: 148.0.7778.280
Node.js: 24.18.1
V8: 14.8.178.38-electron.0
xterm.js: 6.1.0-beta.291
OS: Windows_NT x64 10.0.26300

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey @cong, thanks for the report.

The .cursorignore file only controls what Cursor indexes and what the AI can read. It doesn’t affect the file watcher, search, or extensions running on the server, so it won’t lower memory use there. The entries in yours (/proc/, /sys/, /var/lib/docker/) suggest the SSH window has / (the whole filesystem) open as its folder. On a 2 core / 4 GB server, that alone can push the remote side to its memory limit.

Here’s what usually fixes it:

  1. Open only your project folder: File → Open Folder, then pick something like /root/your-project instead of /.
  2. Press Ctrl+Shift+P, run Preferences: Open Remote Settings (JSON) (SSH: your-host), and add:
    "files.watcherExclude": {
      "**/node_modules/**": true,
      "**/.git/objects/**": true,
      "**/dist/**": true
    },
    "search.exclude": {
      "**/node_modules": true
    }
    
  3. Start a new chat for each task instead of keeping one very long chat going. Very long chats add to memory use on the server.
  4. Optional, but it helps on a 4 GB machine: add a 2 to 4 GB swap file so the server slows down instead of freezing.

If memory still climbs after that, please run this on the server while usage is high and paste the output here, along with the folder path you open in Cursor:

ps -eo pid,rss,args --sort=-rss | head -15

That shows which Cursor process is using the memory.

Hi Colin, thanks for your suggestions. I’ve tried them, but I’m still seeing high memory usage on the remote server.

I ran the command you requested:

ps -eo pid,rss,args --sort=-rss | head -15

In the October 23 capture, the largest Cursor process was the remote extension host. These are the relevant entries, with command arguments shortened for readability. RSS values are in KiB:

PID       RSS       PROCESS
739815    1323404   cursor-server/node … --type=extensionHost
739809      97900   cursor-server/node … --type=fileWatcher
739755      87892   cursor-server/node … out/server-main.js

A second sample approximately 31 seconds later showed the same extensionHost process at 1,383,200 KiB RSS—an increase from about 1,292 MiB to 1,351 MiB. At that point, the process had only been running for 19 minutes.

The server has 2 CPU cores, 4 GB of RAM, and 2 GB of swap. Other services also consume memory, so I’m not attributing all system memory usage to Cursor, but extensionHost was the largest individual process in this capture.

I understand that .cursorignore does not control every watcher or extension. What would be the best next step to identify what is driving memory growth inside the remote extension host? Is there a recommended way to collect a heap profile or diagnostic logs, or to distinguish Cursor’s built-in functionality from third-party extensions?

I can provide the full process output and additional logs if needed.

Hey @cong, thanks for running that and for the numbers.

That capture helps narrow it down. The file watcher is small (about 95 MB), so the folder and watcher changes did their job. The growth is in the remote extension host. On Remote SSH, that one process on your server runs your extensions plus Cursor’s own agent work (tool calls, shell commands, and the working state of open chats), so an active agent session is part of what lands there. A process that is 1.3 GB after 19 minutes and still climbing is more than we’d expect from that alone, so it’s worth pinning down.

Here’s the quickest way to tell Cursor apart from third-party extensions:

  1. Run Developer: Reload Window so the extension host starts fresh.
  2. On the server, log the extension host’s memory every 30 seconds:
    pid=$(pgrep -f 'cursor-server.*--type=extensionHost' | head -1)
    while true; do echo "$(date +%T) $(ps -o rss= -p $pid)"; sleep 30; done
    
  3. Use Cursor the way you normally do for about 30 minutes, and note roughly when an agent chat was running and when it was idle.
  4. Press Ctrl+Shift+P, run Extensions: Disable All Installed Extensions, reload the window, and repeat steps 2 and 3 with a similar agent workload. Cursor’s built-in features stay on.

If memory still climbs with everything disabled, it’s coming from Cursor itself. If it stays flat, one of your extensions is the cause, and Help: Start Extension Bisect will find which one in a few reloads.

While memory is high, a screenshot of Developer: Show Running Extensions is also useful, since it lists what’s running on the server.

4 GB shared with other services is tight for Remote SSH plus an active agent. More memory would give you headroom, but if the growth is steady it would only delay the freeze, which is why the test above matters.