应用程序突然挂起(等待进入 .NET 锁)

时间:2021-04-23 14:38:52

标签: asp.net .net iis

我有一个在 IIS 8.5 上运行的应用程序,它突然挂起。

我已经在确切的时刻转储了内存并试图分析问题,我发现了以下内容:

<块引用>

w3wp.exe_210419_122423.dmp 中的以下线程正在等待进入线程 128 拥有的 .NET 锁

如果我理解了这条消息,这意味着一个线程正在锁定其他线程(76 个线程),但我没有弄清楚到底发生了什么。

查看线程 128,我有以下内容:

Thread 128 - System ID 27172
Entry point   clr!Thread::intermediateThreadProc
Create time   19/04/2021 12:06:21
Time spent in user mode   0 Days 00:00:00.734
Time spent in kernel mode     0 Days 00:00:00.171

This thread is not fully resolved and may or may not be a problem. Further analysis of these threads may be required.

.NET Call Stack

[[HelperMethodFrame_1OBJ] (System.Threading.Thread.AbortInternal)] System.Threading.Thread.AbortInternal()
System.Threading.Thread.Abort(System.Object)+56
System.Web.RequestTimeoutManager+RequestTimeoutEntry.TimeoutIfNeeded(System.DateTime)+42
System.Web.RequestTimeoutManager.CancelTimedOutRequests(System.DateTime)+1a3
System.Web.RequestTimeoutManager.TimerCompletionCallback(System.Object)+1e
System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)+16a
System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)+14
System.Threading.TimerQueueTimer.CallCallback()+13b
System.Threading.TimerQueueTimer.Fire()+8f
System.Threading.TimerQueue.FireNextTimers()+75
[[DebuggerU2MCatchHandlerFrame]]
[[ContextTransitionFrame]]
[[DebuggerU2MCatchHandlerFrame]]

Full Call Stack


Instruction Address       Source
[0x7ffe39ee0c6a]    ntdll!NtWaitForMultipleObjects+a      
[0x7ffe370713ed]    KERNELBASE!WaitForMultipleObjectsEx+e1    
[0x7ffe1dc896be]    clr!WaitForMultipleObjectsEx_SO_TOLERANT+62   
[0x7ffe1dc8951c]    clr!Thread::DoAppropriateWaitWorker+1e4   
[0x7ffe1dc89315]    clr!Thread::DoAppropriateWait+7d      
[0x7ffe1db5f256]    clr!Thread::JoinEx+a2     
[0x7ffe1defe453]    clr!Thread::UserAbort+6d8     
[0x7ffe1e0090f7]    clr!ThreadNative::Abort+117   
[0x7ffdc0913ed6]    System.Threading.Thread.Abort(System.Object)+56   
[0x7ffdc090bd52]    System.Web.RequestTimeoutManager+RequestTimeoutEntry.TimeoutIfNeeded(System.DateTime)+42      
[0x7ffdc090af93]    System.Web.RequestTimeoutManager.CancelTimedOutRequests(System.DateTime)+1a3      
[0x7ffdc0909b7e]    System.Web.RequestTimeoutManager.TimerCompletionCallback(System.Object)+1e    
[0x7ffdbea0c77a]    System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)+16a    
[0x7ffdbea09fe4]    System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)+14     
[0x7ffdbef7ac1b]    System.Threading.TimerQueueTimer.CallCallback()+13b   
[0x7ffdbef7a7af]    System.Threading.TimerQueueTimer.Fire()+8f    
[0x7ffdbef79245]    System.Threading.TimerQueue.FireNextTimers()+75   
[0x7ffe1dae6bb3]    clr!CallDescrWorkerInternal+83    
[0x7ffe1dae6a70]    clr!CallDescrWorkerWithHandler+4e     
[0x7ffe1dae735d]    clr!MethodDescCallSite::CallTargetWorker+f8   
[0x7ffe1dae9ff3]    clr!AppDomainTimerCallback_Worker+23      
[0x7ffe1dae7b21]    clr!ManagedThreadBase_DispatchInner+39    
[0x7ffe1dae7a90]    clr!ManagedThreadBase_DispatchMiddle+6c   
[0x7ffe1dae79cd]    clr!ManagedThreadBase_DispatchOuter+75    
[0x7ffe1daeaa64]    clr!ManagedThreadBase_DispatchInCorrectAD+15      
[0x7ffe1daeab5e]    clr!Thread::DoADCallBack+278      
[0x7ffe1daeaab3]    clr!ManagedThreadBase_DispatchInner+2fd3      
[0x7ffe1dae7a90]    clr!ManagedThreadBase_DispatchMiddle+6c   
[0x7ffe1dae79cd]    clr!ManagedThreadBase_DispatchOuter+75    
[0x7ffe1dae7b5f]    clr!ManagedThreadBase_FullTransitionWithAD+2f     
[0x7ffe1dae9f85]    clr!AppDomainTimerCallback+7f     
[0x7ffe1dae9ee6]    clr!ThreadpoolMgr::AsyncTimerCallbackCompletion+7e    
[0x7ffe1dae99e7]    clr!UnManagedPerAppDomainTPCount::DispatchWorkItem+1bc    
[0x7ffe1dae819c]    clr!ThreadpoolMgr::ExecuteWorkRequest+64      
[0x7ffe1dae7f45]    clr!ThreadpoolMgr::WorkerThreadStart+f5   
[0x7ffe1db92e8f]    clr!Thread::intermediateThreadProc+86     
[0x7ffe375a13d2]    kernel32!BaseThreadInitThunk+22   
[0x7ffe39e654e4]    ntdll!RtlUserThreadStart+34

有谁知道发生了什么,我该如何解决?

谢谢!!

0 个答案:

没有答案