-
Notifications
You must be signed in to change notification settings - Fork 29.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Experimental File Watcher - high CPU on "circular" symlinks #36307
Comments
Just noticed the same thing on osx... |
Same issue here |
Reported upstream Axosoft/nsfw#40 |
Upstream PR Axosoft/nsfw#41 |
The original PR was closed so I opened one which was merged Axosoft/nsfw#47, just need a release to pull this in. |
I have vscode 1.19.2 on Ubuntu. The various node_modules directories have symbolic links point to each other that form the circular links. The node_modules is set excluded in "files.watcherExclude". After vscode is started, it uses 100% CPU and memory usage increased dramatically and soon reached the max memory and hang the system. This problem happens whatever useExperimentalFileWatcher is set true or false. The ps shows the problem code process has parameter '--type=watcherService". Attached gdb to the process, it shows the watcher follows through the circular symbolic links in circular. Set "search.followSymlinks": false has no effect,. So this problem still happens in 1.19.2 even with all the right settings in place. |
@Tyriar is it possible/easy to patch VS Code to stop this behaviour while waiting for it to hit a release? I have a workspace that causes a 20GB VM to exhaust its memory in about 15 mins because of circular symlinks (it uses lerna). |
@jwulf yeah I'll fork the module to get this in, was hoping I wouldn't need to. |
@Tyriar what's the expected behavior after the change? I'm still seeing high CPU on today's insiders version on Mac
|
@RMacfarlane the fix is specific to Linux only when you have experimental file watcher set to true in settings (or you have a multi-root workspace open). |
If you have this issue, it's not just high CPU usage - your memory will be exhausted within minutes. With a workspace with circular symlinks in it (it uses lerna and has circular dependencies), I was seeing 20GB of RAM get sucked up in about 15 minutes. Insiders has had the fix for a while now. |
@jwulf thanks, I'll mark as verified since you saw it before 👍 |
Steps to Reproduce:
Reproduces without extensions: Yes
See also: #3998
The text was updated successfully, but these errors were encountered: