Closed
Description
- Version: v10.16.3 (we're using nave)
- Platform: Linux zagent 4.4.0-159-generic configure: remove workarounds for GCC < 4.8 #187-Ubuntu SMP Thu Aug 1 16:28:06 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
- Subsystem: http2
I have been making a lot of requests to the service (like in #29902) and after that I send SIGUSR2 to the service process to take heap snapshot. And service crashed with a segmentation fault.
Core was generated by `/var/lib/nave/installed/10.16.3/bin/node --expose-internals --expose-gc --max-h'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x0000000001a66b35 in node::MemoryRetainerNode::MemoryRetainerNode (this=0x6e95f10, tracker=0x7ffc9b58b9e0, retainer=0xb3be530) at ../src/memory_tracker-inl.h:29
29 v8::Local<v8::Object> obj = retainer_->WrappedObject();
[Current thread is 1 (Thread 0x7f9641872740 (LWP 30235))]
(gdb) bt
#0 0x0000000001a66b35 in node::MemoryRetainerNode::MemoryRetainerNode (this=0x6e95f10, tracker=0x7ffc9b58b9e0, retainer=0xb3be530) at ../src/memory_tracker-inl.h:29
#1 0x0000000001a67185 in node::MemoryTracker::AddNode (this=0x7ffc9b58b9e0, retainer=0xb3be530, edge_name=0x320201e "session") at ../src/memory_tracker-inl.h:263
#2 0x0000000001a6741a in node::MemoryTracker::PushNode (this=0x7ffc9b58b9e0, retainer=0xb3be530, edge_name=0x320201e "session") at ../src/memory_tracker-inl.h:297
#3 0x0000000001a66ff9 in node::MemoryTracker::Track (this=0x7ffc9b58b9e0, retainer=0xb3be530, edge_name=0x320201e "session") at ../src/memory_tracker-inl.h:244
#4 0x0000000001a66ea6 in node::MemoryTracker::TrackField (this=0x7ffc9b58b9e0, edge_name=0x320201e "session", value=0xb3be530, node_name=0x0) at ../src/memory_tracker-inl.h:100
#5 0x0000000001b455a6 in node::http2::Http2Session::Http2Settings::MemoryInfo (this=0xc3588f0, tracker=0x7ffc9b58b9e0) at ../src/node_http2.h:1160
#6 0x0000000001a6701b in node::MemoryTracker::Track (this=0x7ffc9b58b9e0, retainer=0xc3588f0, edge_name=0x0) at ../src/memory_tracker-inl.h:245
#7 0x0000000001a7bcb3 in node::Environment::<lambda(node::BaseObject*)>::operator()(node::BaseObject *) const (__closure=0x7ffc9b58b9d0, obj=0xc3588f0) at ../src/env.cc:718
#8 0x0000000001a7c0de in node::Environment::ForEachBaseObject<node::Environment::BuildEmbedderGraph(v8::Isolate*, v8::EmbedderGraph*, void*)::<lambda(node::BaseObject*)> >(<unknown type in /var/lib/nave/installed/10.16.3/bin/node, CU 0x2f408c, DIE 0x3762f7>) (this=0x7ffc9b591610, iterator=<unknown type in /var/lib/nave/installed/10.16.3/bin/node, CU 0x2f408c, DIE 0x3762f7>)
at ../src/env-inl.h:856
#9 0x0000000001a7bd2c in node::Environment::BuildEmbedderGraph (isolate=0x64035e0, graph=0x7ffc9b58bbc0, data=0x7ffc9b591610) at ../src/env.cc:719
#10 0x0000000002859880 in v8::internal::HeapProfiler::BuildEmbedderGraph (this=0x6446730, isolate=0x64035e0, graph=0x7ffc9b58bbc0) at ../deps/v8/src/profiler/heap-profiler.cc:94
#11 0x00000000028773df in v8::internal::NativeObjectsExplorer::IterateAndExtractReferences (this=0x7ffc9b58bdf0, filler=0x7ffc9b58bc30) at ../deps/v8/src/profiler/heap-snapshot-generator.cc:2293
#12 0x0000000002878344 in v8::internal::HeapSnapshotGenerator::FillReferences (this=0x7ffc9b58bcf0) at ../deps/v8/src/profiler/heap-snapshot-generator.cc:2516
#13 0x00000000028780b9 in v8::internal::HeapSnapshotGenerator::GenerateSnapshot (this=0x7ffc9b58bcf0) at ../deps/v8/src/profiler/heap-snapshot-generator.cc:2470
#14 0x0000000002859998 in v8::internal::HeapProfiler::TakeSnapshot (this=0x6446730, control=0x0, resolver=0x0) at ../deps/v8/src/profiler/heap-profiler.cc:104
#15 0x0000000001e6a1c5 in v8::HeapProfiler::TakeHeapSnapshot (this=0x6446730, control=0x0, resolver=0x0) at ../deps/v8/src/api.cc:10480
#16 0x00007f9625b4d004 in (anonymous namespace)::WriteSnapshot(v8::FunctionCallbackInfo<v8::Value> const&) () from /var/cache/znpm64/heapdump-0.3.7/build/Release/addon.node
#17 0x0000000001f377d4 in v8::internal::FunctionCallbackArguments::Call (this=0x7ffc9b58d180, handler=0x1782bf8db941) at ../deps/v8/src/api-arguments-inl.h:94
#18 0x0000000001f3a5fa in v8::internal::(anonymous namespace)::HandleApiCallHelper<false> (isolate=0x64035e0, function=..., new_target=..., fun_data=..., receiver=..., args=...)
at ../deps/v8/src/builtins/builtins-api.cc:109
#19 0x0000000001f384f0 in v8::internal::Builtin_Impl_HandleApiCall (args=..., isolate=0x64035e0) at ../deps/v8/src/builtins/builtins-api.cc:139
#20 0x0000000001f38271 in v8::internal::Builtin_HandleApiCall (args_length=6, args_object=0x7ffc9b58d3a0, isolate=0x64035e0) at ../deps/v8/src/builtins/builtins-api.cc:127
#21 0x000034e86e8c1d64 in ?? ()
#22 0x000034e86e8c1cc1 in ?? ()
#23 0x00007ffc9b58d350 in ?? ()
#24 0x0000000000000006 in ?? ()
#25 0x00007ffc9b58d3e8 in ?? ()
#26 0x000034e86e7a0ab6 in ?? ()
#27 0x00000ccf204026f1 in ?? ()
#28 0x00001782bf8db9d1 in ?? ()
#29 0x0000000600000000 in ?? ()
#30 0x00000ccf20402801 in ?? ()
#31 0x0000034306c9d369 in ?? ()
#32 0x00001e996428d481 in ?? ()
#33 0x00000ccf204022b1 in ?? ()
#34 0x00001782bf8db9d1 in ?? ()
#35 0x000039fb67984a19 in ?? ()
#36 0x0000034306c9d3a1 in ?? ()
#37 0x0000005000000000 in ?? ()
#38 0x000007754167fe01 in ?? ()
#39 0x00001782bf8dba79 in ?? ()
#40 0x00002b96738db5e1 in ?? ()
#41 0x00007ffc9b58d420 in ?? ()
#42 0x000034e86e78f303 in ?? ()
#43 0x0000088e1c58a771 in ?? ()
#44 0x0000000000000000 in ?? ()
in node source code added 2 lines - see #29902 (comment)