nodejs / help

:sparkles: Need help with Node.js? File an Issue here. :rocket:
1.44k stars 276 forks source link

Linux Mint 21.2 Cinnamon - Aborted (core dumped) #4310

Closed Sofitt closed 2 days ago

Sofitt commented 7 months ago

On Windows 10, the project launches in dev mode, but due to a memory leak, it crashes after some time. This occurs following several recompilations. We don't have a specialist who could identify and fix the leak, so we just restart the dev.

However, on Linux Mint 21.2 Cinnamon (i am inexperienced with Linux, but other nodejs projects works fine), after launching in dev mode, the build completes, and the console displays 'No issues found'. But upon accessing localhost:3000, as the page begins to load, the system monitor shows that the node process progressively increases its memory usage until it reaches the ceiling of 4 GB, after which it crashes. During this time, the page remains inactive (white screen). Increasing --max-old-space-size does not solve the problem. My collegue using Ubuntu and he dont have problem to start project.

[13892:0x60d3c00] 193113 ms: Mark-sweep 3920.7 (4047.9) -> 3917.4 (4047.9) MB, 1220.3 / 0.0 ms (average mu = 0.139, current mu = 0.106) allocation failure; GC in old space requested [13892:0x60d3c00] 194346 ms: Mark-sweep 3918.3 (4047.9) -> 3917.6 (4048.2) MB, 1226.3 / 0.0 ms (average mu = 0.071, current mu = 0.006) allocation failure; GC in old space requested

<--- JS stacktrace --->

FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory 1: 0xb85bc0 node::Abort() [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 2: 0xa94834 [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 3: 0xd66d10 v8::Utils::ReportOOMFailure(v8::internal::Isolate, char const, bool) [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 4: 0xd670b7 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate, char const, bool) [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 5: 0xf447c5 [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 6: 0xf56cad v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 7: 0xf313ae v8::internal::HeapAllocator::AllocateRawWithLightRetrySlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 8: 0xf32777 v8::internal::HeapAllocator::AllocateRawWithRetryOrFailSlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 9: 0xf1394a v8::internal::Factory::NewFillerObject(int, v8::internal::AllocationAlignment, v8::internal::AllocationType, v8::internal::AllocationOrigin) [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 10: 0x12d8e6d v8::internal::Runtime_AllocateInOldGeneration(int, unsigned long, v8::internal::Isolate) [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] 11: 0x1705b39 [/home/sofit/.nvm/versions/node/v18.18.2/bin/node] Aborted (core dumped)


I also have memory dump, it was recorded while page loading (I stopped recording after the crash, I don’t know if this will be useful):
[Heap-20231203T155235.heaptimeline.tar.gz](https://github.com/nodejs/node/files/13538485/Heap-20231203T155235.heaptimeline.tar.gz)
marco-ippolito commented 7 months ago

What makes you think the leak it's related to a Node.js bug?

Sofitt commented 7 months ago

What makes you think the leak it's related to a Node.js bug?

This is not a bug, I think. I just need some help solving a problem

marco-ippolito commented 7 months ago

@Sofitt The nodejs/node is for issue relative to nodejs core, moved to nodejs/help since it's a help request

github-actions[bot] commented 1 month ago

It seems there has been no activity on this issue for a while, and it is being closed in 30 days. If you believe this issue should remain open, please leave a comment. If you need further assistance or have questions, you can also search for similar issues on Stack Overflow. Make sure to look at the README file for the most updated links.

github-actions[bot] commented 2 days ago

It seems there has been no activity on this issue for a while, and it is being closed. If you believe this issue should remain open, please leave a comment. If you need further assistance or have questions, you can also search for similar issues on Stack Overflow. Make sure to look at the README file for the most updated links.