Skip to content
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

Error Javascript heap out of memory #43

Open
kingekartik opened this issue Jan 12, 2019 · 4 comments
Open

Error Javascript heap out of memory #43

kingekartik opened this issue Jan 12, 2019 · 4 comments

Comments

@kingekartik
Copy link

kingekartik commented Jan 12, 2019

Brief: While uploading a 400mb file using this tool, I get Javascript heap overflow error.

Command used:

firebase-import --database_url https://database.firebaseio.com/ --path / --json C:\User\Desktop\file.json --service_account C:\Users\service_account.json

Complete Error log:

<--- Last few GCs ---> [4052:000002065D718290] 155635 ms: Mark-sweep 1375.3 (1399.6) -> 1375.3 (1399.6) MB, 3254.4 / 0.0 ms (average mu = 0.091, current mu = 0.000) last resort GC in old space requested [4052:000002065D718290] 158828 ms: Mark-sweep 1375.3 (1399.6) -> 1375.3 (1399.6) MB, 3192.5 / 0.0 ms (average mu = 0.047, current mu = 0.000) last resort GC in old space requested <--- JS stacktrace ---> ==== JS stack trace ========================================= 0: ExitFrame [pc: 000000079E2DC5C1] Security context: 0x00d110a08ce9 1: push [000002490F19CC39](this=0x031861c9b181 <JSArray[1956331]>,0x02b158d904a1 ) 2: chunkInternal [000000C0F32CEA41] [C:\Users\firebase-import.js:~179] [pc=000000079E5D300A](this=0x001a0279ad11 ,ref=0x031861c9b1a1 <Reference map = 000002D... FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory 1: 00007FF78778121A v8::internal::GCIdleTimeHandler::GCIdleTimeHandler+4810 2: 00007FF78775A5B6 node::MakeCallback+4518 3: 00007FF78775AFA0 node_module_register+2160 4: 00007FF7879EB3EE v8::internal::FatalProcessOutOfMemory+846 5: 00007FF7879EB31F v8::internal::FatalProcessOutOfMemory+639 6: 00007FF787F29304 v8::internal::Heap::MaxHeapGrowingFactor+11476 7: 00007FF787F27098 v8::internal::Heap::MaxHeapGrowingFactor+2664 8: 00007FF787AC9C08 v8::internal::Factory::AllocateRawArray+56 9: 00007FF787ACA582 v8::internal::Factory::NewFixedArrayWithFiller+66 10: 00007FF787B3F91C v8::internal::HashTablev8::internal::NumberDictionary,v8::internal::NumberDictionaryShape::KeyAt+43820 11: 00007FF787B3F59D v8::internal::HashTablev8::internal::NumberDictionary,v8::internal::NumberDictionaryShape::KeyAt+42925 12: 00007FF787B33396 v8::internal::HashTablev8::internal::NumberDictionary,v8::internal::NumberDictionaryShape::EntryToIndex+71382 13: 00007FF787D061CE v8::internal::SharedFunctionInfo::SetScript+23662 14: 00007FF787CE8CA3 v8::internal::JSReceiver::class_name+20931 15: 00007FF787AB9FD1 v8::internal::wasm::WasmCodeManager::LookupCode+18929 16: 00007FF787ABD068 v8::internal::wasm::WasmCodeManager::LookupCode+31368 17: 000000079E2DC5C1

@PedroMazarini
Copy link

Did you find a solution for this?

@kingekartik
Copy link
Author

kingekartik commented Jan 21, 2019 via email

@banghasan
Copy link

banghasan commented Aug 25, 2019

For me, file size 913M :

node --max-old-space-size=8192 /usr/local/bin/firebase-import ...

and solve.

@qbasic16
Copy link

I am just in the process of importing a 2.82 GB JSON file... and it seems to work 😎

firebase-import-3gb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants