MongoDB service down on Windows: Failed to open minidump file

Good day.

First, I know they are many posts that relate to my issue, but none provided me with a fix. :frowning:

Running:
Mongo Server Community 7.0.2
Windows Server 2019

The mongoDB server has been running smoothly for 2 months, but suddenly this problem appeared

Following is the what have i observe:

  1. MongoDB should have all rights to access the folder
  2. There is no file “mongod.2024-06-22T19-55-10.mdmp” in the folder

Here’s a snipped of the log file:

Blockquote
{“t”:{“$date”:“2024-06-23T03:55:07.017+08:00”},“s”:“F”, “c”:“CONTROL”, “id”:6384300, “ctx”:“ftdc”,“msg”:“Writing fatal message”,“attr”:{“message”:“terminate() called. An exception is active; attempting to gather more information\n”}}
{“t”:{“$date”:“2024-06-23T03:55:07.020+08:00”},“s”:“F”, “c”:“CONTROL”, “id”:6384300, “ctx”:“ftdc”,“msg”:“Writing fatal message”,“attr”:{“message”:“DBException::toString(): FileRenameFailed: Access is denied\nActual exception type: class mongo::error_details::ExceptionForImpl<37,class mongo::AssertionException>\n\n”}}
{“t”:{“$date”:“2024-06-23T03:55:07.020+08:00”},“s”:“F”, “c”:“CONTROL”, “id”:6384300, “ctx”:“ftdc”,“msg”:“Writing fatal message”,“attr”:{“message”:“\n”}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31380, “ctx”:“ftdc”,“msg”:“BACKTRACE”,“attr”:{“bt”:{“backtrace”:[{“a”:“7FF7D705F2F1”,“module”:“mongod.exe”,“file”:“…/src/mongo/util/stacktrace_windows.cpp”,“line”:336,“s”:“mongo::printStackTrace”,“s+”:“41”},{“a”:“7FF7D7062AB8”,“module”:“mongod.exe”,“file”:“…/src/mongo/util/signal_handlers_synchronous.cpp”,“line”:261,“s”:“mongo::anonymous namespace'::myTerminate","s+":"E8"},{"a":"7FF7D7114937","module":"mongod.exe","file":".../src/mongo/stdx/set_terminate_internals.cpp","line":87,"s":"mongo::stdx::dispatch_impl","s+":"17"},{"a":"7FF7D7114919","module":"mongod.exe","file":".../src/mongo/stdx/set_terminate_internals.cpp","line":91,"s":"mongo::stdx::TerminateHandlerDetailsInterface::dispatch","s+":"9"},{"a":"7FFD2A48DE58","module":"ucrtbase.dll","s":"terminate","s+":"18"},{"a":"7FFD1C821AAB","module":"VCRUNTIME140_1.dll","s":"_NLG_Return2","s+":"95B"},{"a":"7FFD1C822317","module":"VCRUNTIME140_1.dll","s":"_NLG_Return2","s+":"11C7"},{"a":"7FFD1C82237A","module":"VCRUNTIME140_1.dll","s":"_NLG_Return2","s+":"122A"},{"a":"7FFD1C824159","module":"VCRUNTIME140_1.dll","s":"_CxxFrameHandler4","s+":"A9"},{"a":"7FF7D7351EFC","module":"mongod.exe","file":"d:/a01/_work/43/s/src/vctools/crt/vcstartup/src/gs/amd64/gshandlereh4.cpp","line":86,"s":"__GSHandlerCheck_EH4","s+":"64"},{"a":"7FFD2D4F4C2F","module":"ntdll.dll","s":"_chkstk","s+":"11F"},{"a":"7FFD2D454CEF","module":"ntdll.dll","s":"RtlWalkFrameChain","s+":"14BF"},{"a":"7FFD2D458AE6","module":"ntdll.dll","s":"RtlRaiseException","s+":"316"},{"a":"7FFD29F01B29","module":"KERNELBASE.dll","s":"RaiseException","s+":"69"},{"a":"7FFD1C836720","module":"VCRUNTIME140.dll","s":"CxxThrowException","s+":"90"},{"a":"7FF7D70DA81D","module":"mongod.exe","file":"C:/data/mci/68ba94354ad8cf044adffc9e61a076ff/src/build/opt/mongo/base/error_codes.cpp","line":2592,"s":"mongo::error_details::throwExceptionForStatus","s+":"42D"},{"a":"7FF7D706C5EE","module":"mongod.exe","file":".../src/mongo/util/assert_util.cpp","line":282,"s":"mongo::uassertedWithLocation","s+":"19E"},{"a":"7FF7D51C8640","module":"mongod.exe","file":".../src/mongo/db/ftdc/controller.cpp","line":256,"s":"mongo::FTDCController::doLoop","s+":"5B0"},{"a":"7FF7D51C7F2C","module":"mongod.exe","file":"C:/Program Files/Microsoft Visual Studio/2022/Professional/VC/Tools/MSVC/14.31.31103/include/thread","line":56,"s":"std::thread::_Invoke<std::tuple<mongo::stdx::thread::thread<mongo::FTDCController::start'::2’::<lambda_2>,0>‘::1'::<lambda_4_> >,0>","s+":"2C"},{"a":"7FFD2A44268A","module":"ucrtbase.dll","s":"o_exp","s+":"5A"},{"a":"7FFD2B557AC4","module":"KERNEL32.DLL","s":"BaseThreadInitThunk","s+":"14"}]}},"tags":[]} {"t":{"$date":"2024-06-23T03:55:10.973+08:00"},"s":"I", "c":"CONTROL", "id":31445, "ctx":"ftdc","msg":"Frame","attr":{"frame":{"a":"7FF7D705F2F1","module":"mongod.exe","file":".../src/mongo/util/stacktrace_windows.cpp","line":336,"s":"mongo::printStackTrace","s+":"41"}}} {"t":{"$date":"2024-06-23T03:55:10.973+08:00"},"s":"I", "c":"CONTROL", "id":31445, "ctx":"ftdc","msg":"Frame","attr":{"frame":{"a":"7FF7D7062AB8","module":"mongod.exe","file":".../src/mongo/util/signal_handlers_synchronous.cpp","line":261,"s":"mongo::anonymous namespace’::myTerminate”,“s+”:“E8”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D7114937”,“module”:“mongod.exe”,“file”:“…/src/mongo/stdx/set_terminate_internals.cpp”,“line”:87,“s”:“mongo::stdx::dispatch_impl”,“s+”:“17”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D7114919”,“module”:“mongod.exe”,“file”:“…/src/mongo/stdx/set_terminate_internals.cpp”,“line”:91,“s”:“mongo::stdx::TerminateHandlerDetailsInterface::dispatch”,“s+”:“9”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2A48DE58”,“module”:“ucrtbase.dll”,“s”:“terminate”,“s+”:“18”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C821AAB”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“95B”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C822317”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“11C7”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C82237A”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“122A”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C824159”,“module”:“VCRUNTIME140_1.dll”,“s”:“_CxxFrameHandler4”,“s+”:“A9”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D7351EFC”,“module”:“mongod.exe”,“file”:“d:/a01/_work/43/s/src/vctools/crt/vcstartup/src/gs/amd64/gshandlereh4.cpp”,“line”:86,“s”:“__GSHandlerCheck_EH4”,“s+”:“64”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2D4F4C2F”,“module”:“ntdll.dll”,“s”:“_chkstk”,“s+”:“11F”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2D454CEF”,“module”:“ntdll.dll”,“s”:“RtlWalkFrameChain”,“s+”:“14BF”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2D458AE6”,“module”:“ntdll.dll”,“s”:“RtlRaiseException”,“s+”:“316”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD29F01B29”,“module”:“KERNELBASE.dll”,“s”:“RaiseException”,“s+”:“69”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C836720”,“module”:“VCRUNTIME140.dll”,“s”:“CxxThrowException”,“s+”:“90”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D70DA81D”,“module”:“mongod.exe”,“file”:“C:/data/mci/68ba94354ad8cf044adffc9e61a076ff/src/build/opt/mongo/base/error_codes.cpp”,“line”:2592,“s”:“mongo::error_details::throwExceptionForStatus”,“s+”:“42D”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D706C5EE”,“module”:“mongod.exe”,“file”:“…/src/mongo/util/assert_util.cpp”,“line”:282,“s”:“mongo::uassertedWithLocation”,“s+”:“19E”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D51C8640”,“module”:“mongod.exe”,“file”:“…/src/mongo/db/ftdc/controller.cpp”,“line”:256,“s”:“mongo::FTDCController::doLoop”,“s+”:“5B0”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.973+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D51C7F2C”,“module”:“mongod.exe”,“file”:“C:/Program Files/Microsoft Visual Studio/2022/Professional/VC/Tools/MSVC/14.31.31103/include/thread”,“line”:56,“s”:“std::thread::Invoke<std::tuple<mongo::stdx::thread::thread<mongo::FTDCController::start’::2'::<lambda_2>,0>'::1’::<lambda_4> >,0>”,“s+”:“2C”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.974+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2A44268A”,“module”:“ucrtbase.dll”,“s”:“o_exp”,“s+”:“5A”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.974+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2B557AC4”,“module”:“KERNEL32.DLL”,“s”:“BaseThreadInitThunk”,“s+”:“14”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.974+08:00”},“s”:“F”, “c”:“CONTROL”, “id”:23134, “ctx”:“ftdc”,“msg”:“Unhandled exception”,“attr”:{“exceptionString”:“0xE0000001”,“addressString”:“0x00007FFD29F01B29”}}
{“t”:{“$date”:“2024-06-23T03:55:10.974+08:00”},“s”:“F”, “c”:“CONTROL”, “id”:23136, “ctx”:“ftdc”,“msg”:“*** stack trace for unhandled exception:”}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31380, “ctx”:“ftdc”,“msg”:“BACKTRACE”,“attr”:{“bt”:{“backtrace”:[{“a”:“7FFD29F01B29”,“module”:“KERNELBASE.dll”,“s”:“RaiseException”,“s+”:“69”},{“a”:“7FF7D7062139”,“module”:“mongod.exe”,“file”:“…/src/mongo/util/signal_handlers_synchronous.cpp”,“line”:103,“s”:“mongo::anonymous namespace'::endProcessWithSignal","s+":"19"},{"a":"7FF7D7062AC7","module":"mongod.exe","file":".../src/mongo/util/signal_handlers_synchronous.cpp","line":262,"s":"mongo::anonymous namespace’::myTerminate”,“s+”:“F7”},{“a”:“7FF7D7114937”,“module”:“mongod.exe”,“file”:“…/src/mongo/stdx/set_terminate_internals.cpp”,“line”:87,“s”:“mongo::stdx::dispatch_impl”,“s+”:“17”},{“a”:“7FF7D7114919”,“module”:“mongod.exe”,“file”:“…/src/mongo/stdx/set_terminate_internals.cpp”,“line”:91,“s”:“mongo::stdx::TerminateHandlerDetailsInterface::dispatch”,“s+”:“9”},{“a”:“7FFD2A48DE58”,“module”:“ucrtbase.dll”,“s”:“terminate”,“s+”:“18”},{“a”:“7FFD1C821AAB”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“95B”},{“a”:“7FFD1C822317”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“11C7”},{“a”:“7FFD1C82237A”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“122A”},{“a”:“7FFD1C824159”,“module”:“VCRUNTIME140_1.dll”,“s”:“_CxxFrameHandler4”,“s+”:“A9”},{“a”:“7FF7D7351EFC”,“module”:“mongod.exe”,“file”:“d:/a01/_work/43/s/src/vctools/crt/vcstartup/src/gs/amd64/gshandlereh4.cpp”,“line”:86,“s”:“__GSHandlerCheck_EH4”,“s+”:“64”},{“a”:“7FFD2D4F4C2F”,“module”:“ntdll.dll”,“s”:“_chkstk”,“s+”:“11F”},{“a”:“7FFD2D454CEF”,“module”:“ntdll.dll”,“s”:“RtlWalkFrameChain”,“s+”:“14BF”},{“a”:“7FFD2D458AE6”,“module”:“ntdll.dll”,“s”:“RtlRaiseException”,“s+”:“316”},{“a”:“7FFD29F01B29”,“module”:“KERNELBASE.dll”,“s”:“RaiseException”,“s+”:“69”},{“a”:“7FFD1C836720”,“module”:“VCRUNTIME140.dll”,“s”:“CxxThrowException”,“s+”:“90”},{“a”:“7FF7D70DA81D”,“module”:“mongod.exe”,“file”:“C:/data/mci/68ba94354ad8cf044adffc9e61a076ff/src/build/opt/mongo/base/error_codes.cpp”,“line”:2592,“s”:“mongo::error_details::throwExceptionForStatus”,“s+”:“42D”},{“a”:“7FF7D706C5EE”,“module”:“mongod.exe”,“file”:“…/src/mongo/util/assert_util.cpp”,“line”:282,“s”:“mongo::uassertedWithLocation”,“s+”:“19E”},{“a”:“7FF7D51C8640”,“module”:“mongod.exe”,“file”:“…/src/mongo/db/ftdc/controller.cpp”,“line”:256,“s”:“mongo::FTDCController::doLoop”,“s+”:“5B0”},{“a”:“7FF7D51C7F2C”,“module”:“mongod.exe”,“file”:“C:/Program Files/Microsoft Visual Studio/2022/Professional/VC/Tools/MSVC/14.31.31103/include/thread”,“line”:56,“s”:“std::thread::Invoke<std::tuple<mongo::stdx::thread::thread<mongo::FTDCController::start’::2'::<lambda_2>,0>'::1’::<lambda_4> >,0>”,“s+”:“2C”},{“a”:“7FFD2A44268A”,“module”:“ucrtbase.dll”,“s”:“o_exp”,“s+”:“5A”},{“a”:“7FFD2B557AC4”,“module”:“KERNEL32.DLL”,“s”:“BaseThreadInitThunk”,“s+”:“14”}]}},“tags”:}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD29F01B29”,“module”:“KERNELBASE.dll”,“s”:“RaiseException”,“s+”:“69”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D7062139”,“module”:“mongod.exe”,“file”:“…/src/mongo/util/signal_handlers_synchronous.cpp”,“line”:103,“s”:“mongo::anonymous namespace'::endProcessWithSignal","s+":"19"}}} {"t":{"$date":"2024-06-23T03:55:10.979+08:00"},"s":"I", "c":"CONTROL", "id":31445, "ctx":"ftdc","msg":"Frame","attr":{"frame":{"a":"7FF7D7062AC7","module":"mongod.exe","file":".../src/mongo/util/signal_handlers_synchronous.cpp","line":262,"s":"mongo::anonymous namespace’::myTerminate”,“s+”:“F7”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D7114937”,“module”:“mongod.exe”,“file”:“…/src/mongo/stdx/set_terminate_internals.cpp”,“line”:87,“s”:“mongo::stdx::dispatch_impl”,“s+”:“17”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D7114919”,“module”:“mongod.exe”,“file”:“…/src/mongo/stdx/set_terminate_internals.cpp”,“line”:91,“s”:“mongo::stdx::TerminateHandlerDetailsInterface::dispatch”,“s+”:“9”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2A48DE58”,“module”:“ucrtbase.dll”,“s”:“terminate”,“s+”:“18”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C821AAB”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“95B”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C822317”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“11C7”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C82237A”,“module”:“VCRUNTIME140_1.dll”,“s”:“_NLG_Return2”,“s+”:“122A”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C824159”,“module”:“VCRUNTIME140_1.dll”,“s”:“_CxxFrameHandler4”,“s+”:“A9”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D7351EFC”,“module”:“mongod.exe”,“file”:“d:/a01/_work/43/s/src/vctools/crt/vcstartup/src/gs/amd64/gshandlereh4.cpp”,“line”:86,“s”:“__GSHandlerCheck_EH4”,“s+”:“64”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2D4F4C2F”,“module”:“ntdll.dll”,“s”:“_chkstk”,“s+”:“11F”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2D454CEF”,“module”:“ntdll.dll”,“s”:“RtlWalkFrameChain”,“s+”:“14BF”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2D458AE6”,“module”:“ntdll.dll”,“s”:“RtlRaiseException”,“s+”:“316”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.979+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD29F01B29”,“module”:“KERNELBASE.dll”,“s”:“RaiseException”,“s+”:“69”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD1C836720”,“module”:“VCRUNTIME140.dll”,“s”:“CxxThrowException”,“s+”:“90”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D70DA81D”,“module”:“mongod.exe”,“file”:“C:/data/mci/68ba94354ad8cf044adffc9e61a076ff/src/build/opt/mongo/base/error_codes.cpp”,“line”:2592,“s”:“mongo::error_details::throwExceptionForStatus”,“s+”:“42D”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D706C5EE”,“module”:“mongod.exe”,“file”:“…/src/mongo/util/assert_util.cpp”,“line”:282,“s”:“mongo::uassertedWithLocation”,“s+”:“19E”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D51C8640”,“module”:“mongod.exe”,“file”:“…/src/mongo/db/ftdc/controller.cpp”,“line”:256,“s”:“mongo::FTDCController::doLoop”,“s+”:“5B0”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FF7D51C7F2C”,“module”:“mongod.exe”,“file”:“C:/Program Files/Microsoft Visual Studio/2022/Professional/VC/Tools/MSVC/14.31.31103/include/thread”,“line”:56,“s”:“std::thread::Invoke<std::tuple<mongo::stdx::thread::thread<mongo::FTDCController::start’::2'::<lambda_2>,0>'::1’::<lambda_4> >,0>”,“s+”:“2C”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2A44268A”,“module”:“ucrtbase.dll”,“s”:“o_exp”,“s+”:“5A”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:31445, “ctx”:“ftdc”,“msg”:“Frame”,“attr”:{“frame”:{“a”:“7FFD2B557AC4”,“module”:“KERNEL32.DLL”,“s”:“BaseThreadInitThunk”,“s+”:“14”}}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“I”, “c”:“CONTROL”, “id”:23131, “ctx”:“ftdc”,“msg”:“Failed to open minidump file”,“attr”:{“dumpName”:“C:\Program Files\MongoDB\Server\7.0\bin\mongod.2024-06-22T19-55-10.mdmp”,“error”:“Access is denied.”}}
{“t”:{“$date”:“2024-06-23T03:55:10.980+08:00”},“s”:“F”, “c”:“CONTROL”, “id”:23137, “ctx”:“ftdc”,“msg”:“*** immediate exit due to unhandled exception”}

Blockquote

May I ask what is the root cause of this problem? Isn’t there a way to automatically restart the MongoDB service in Windows if MongoDB suddenly crashes?

Welcome Wui to our community!
The provided logs recommnd that it is a permission/rights issue. One of the common issues that can cause such issue is Window Antivirus software. The Antivirus may lock file access and this will bring mongod process down. Please consider excluding storage.dbPath from such software, to allow MongoDB Server process to function correctly.

The cause of the process crash itself is likely due to permissions error when renaming the metrics.interim.temp file to metrics.interim. Please make sure that no other processes are reading or writing the metrics.interim file.

This has been addressed in https://jira.mongodb.org/browse/SERVER-71274 .
I hope this helps.