Skip to content

OOM with large workspace #298

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

Closed
broady opened this issue Mar 19, 2019 · 3 comments
Closed

OOM with large workspace #298

broady opened this issue Mar 19, 2019 · 3 comments
Labels
bug Something isn't working

Comments

@broady
Copy link

broady commented Mar 19, 2019

Description

<--- Last few GCs --->

[147977:0x2dfe110] 11783883 ms: Mark-sweep 1236.8 (1453.4) -> 1236.8 (1453.4) MB, 1701.2 / 0.1 ms  allocation failure GC in old space requested
[147977:0x2dfe110] 11785728 ms: Mark-sweep 1236.8 (1453.4) -> 1236.8 (1435.9) MB, 1844.5 / 0.1 ms  last resort GC in old space requested
[147977:0x2dfe110] 11787473 ms: Mark-sweep 1236.8 (1435.9) -> 1236.8 (1432.9) MB, 1745.2 / 0.1 ms  last resort GC in old space requested


<--- JS stacktrace --->

==== JS stack trace =========================================

Security context: 0x8741f2a58b9 <JSObject>
    1: createContext(aka createContext) [vm.js:75] [bytecode=0x3cf993e2e269 offset=31](this=0x2719e10022d1 <undefined>,sandbox=0x37d3cb6c9241 <Object map = 0x22b9c4662c31>)
    2: runInNewContext [vm.js:124] [bytecode=0x3cf993e394f1 offset=5](this=0x1413721a7c29 <Object map = 0x22b9c4632b91>,code=0x37d3cb6c93b1 <String[450]: (function(e,t){var n=require("fs"),i=require("util"),r=require("tslib");...

FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
 1: node::Abort() [./code-server]
 2: 0x8ccc1c [./code-server]
 3: v8::Utils::ReportOOMFailure(char const*, bool) [./code-server]
 4: v8::internal::V8::FatalProcessOutOfMemory(char const*, bool) [./code-server]
 5: v8::internal::Factory::NewUninitializedFixedArray(int) [./code-server]
 6: v8::internal::WeakFixedArray::Allocate(v8::internal::Isolate*, int, v8::internal::Handle<v8::internal::WeakFixedArray>) [./code-server]
 7: v8::internal::WeakFixedArray::Add(v8::internal::Handle<v8::internal::Object>, v8::internal::Handle<v8::internal::HeapObject>, int*) [./code-server]
 8: v8::internal::Factory::NewSharedFunctionInfo(v8::internal::MaybeHandle<v8::internal::String>, v8::internal::MaybeHandle<v8::internal::Code>, bool, v8::internal::FunctionKind) [./code-server]
 9: v8::internal::FunctionTemplateInfo::GetOrCreateSharedFunctionInfo(v8::internal::Isolate*, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::MaybeHandle<v8::internal::Name>) [./code-server]
10: v8::internal::ApiNatives::CreateApiFunction(v8::internal::Isolate*, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::ApiNatives::ApiInstanceType, v8::internal::MaybeHandle<v8::internal::Name>) [./code-server]
11: v8::internal::ApiNatives::InstantiateFunction(v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::MaybeHandle<v8::internal::Name>) [./code-server]
12: v8::internal::InstallFunc(v8::internal::Isolate*, v8::internal::Handle<v8::internal::JSObject>, char const*, void (*)(v8::FunctionCallbackInfo<v8::Value> const&), int) [./code-server]
13: v8::internal::WasmJs::Install(v8::internal::Isolate*) [./code-server]
14: v8::internal::Genesis::InstallSpecialObjects(v8::internal::Handle<v8::internal::Context>) [./code-server]
15: v8::internal::Bootstrapper::CreateEnvironment(v8::internal::MaybeHandle<v8::internal::JSGlobalProxy>, v8::Local<v8::ObjectTemplate>, v8::ExtensionConfiguration*, unsigned long, v8::DeserializeInternalFieldsCallback, v8::internal::GlobalContextType) [./code-server]
16: v8::NewContext(v8::Isolate*, v8::ExtensionConfiguration*, v8::MaybeLocal<v8::ObjectTemplate>, v8::MaybeLocal<v8::Value>, unsigned long, v8::DeserializeInternalFieldsCallback) [./code-server]
17: v8::Context::New(v8::Isolate*, v8::ExtensionConfiguration*, v8::MaybeLocal<v8::ObjectTemplate>, v8::MaybeLocal<v8::Value>) [./code-server]
18: 0x8f5dd5 [./code-server]
19: v8::internal::FunctionCallbackArguments::Call(void (*)(v8::FunctionCallbackInfo<v8::Value> const&)) [./code-server]
20: 0xb0fadc [./code-server]
21: v8::internal::Builtin_HandleApiCall(int, v8::internal::Object**, v8::internal::Isolate*) [./code-server]
22: 0x1d7af81842fd
Aborted

Steps to Reproduce

  1. Have a large directory (~/src, in my case, is 12 GB)

  2. Run code-server ~/src

  3. Try to do anything

  4. OOM

@broady broady added the bug Something isn't working label Mar 19, 2019
@kylecarbs
Copy link
Member

Known issue with our file watcher. Will have a fix out quite soon.

@ruslanguns
Copy link

@kylecarbs looking forward for you 👍 thanks in advance!

@code-asher
Copy link
Member

I've been testing out v2 on a 11 GB directory and I think we've resolved the OOM issues. I seem to run at about a constant ~600MB regardless of directory contents. I'll close this out but I'd be interested if anyone else is still experiencing memory issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants