懂windbg的请进来帮忙看一下死锁的有关问题
懂windbg的请进来帮忙看一下死锁的问题
某业务进程死锁,!locks结果如下:
0:000> !locks
CritSec +a50874 at 00a50874
WaiterWoken No
LockCount 7
RecursionCount 1
OwningThread 2c58
EntryCount 0
ContentionCount 53
*** Locked
CritSec +ae8d24 at 00ae8d24
WaiterWoken No
LockCount 50
RecursionCount 30
OwningThread 14b8
EntryCount 0
ContentionCount 4ee
*** Locked
操作系统Win2003 sp2,请问以上的RecursionCount和ContentionCount是什么意思?
这个死锁是如何产生的?
------解决方案--------------------
你还得需要Symbol文件吧,Windows自己和你的产品的Symbol都需要设置上才能看到的吧?
------解决方案--------------------
需要Symbol文件
------解决方案--------------------
缺少符号文件
------解决方案--------------------
给你几个网页吧:
http://www.1qidu.com/?action-viewnews-itemid-4755
RecursionCountRecursionCount字段表示那个拥有线程曾经为这个临界区调用EnterCriticalSection的次数。
EntryCount字段表示除那个拥有线程之外的线程曾经为这个临界区调用EnterCriticalSection的次数。
当第一个线程调用EnterCriticalSection例程的时候,临界区的LockCount、RecursionCount、EntryCount和ContentionCount字段的增量都是加1,而且OwningThread变成这个调用者的线程ID。EntryCount和ContentionCount没有增量。
.....
http://hi.baidu.com/piperworldcup/blog/item/e5baf9e7c9446e26b9382091.html
另外从Windbg自己的帮助文档你搜索RecursionCount:
Interpreting Critical Section Fields in Windows XP and Windows 2000
The most important fields of the critical section structure are as follows:
In Microsoft Windows 2000, and Windows XP, the LockCount field indicates the number of times that any thread has called the EnterCriticalSection routine for this critical section, minus one. This field starts at -1 for an unlocked critical section. Each call of EnterCriticalSection increments this value; each call of LeaveCriticalSection decrements it. For example, if LockCount is 5, this critical section is locked, one thread has acquired it, and five additional threads are waiting for this lock.
The RecursionCount field indicates the number of times that the owning thread has called EnterCriticalSection for this critical section.
The EntryCount field indicates the number of times that a thread other than the owning thread has called EnterCriticalSection for this critical section.
我没用Windbg查死锁,但是 曾经用!analyse -v来判断被测产品在第几行代码Crash...
某业务进程死锁,!locks结果如下:
0:000> !locks
CritSec +a50874 at 00a50874
WaiterWoken No
LockCount 7
RecursionCount 1
OwningThread 2c58
EntryCount 0
ContentionCount 53
*** Locked
CritSec +ae8d24 at 00ae8d24
WaiterWoken No
LockCount 50
RecursionCount 30
OwningThread 14b8
EntryCount 0
ContentionCount 4ee
*** Locked
操作系统Win2003 sp2,请问以上的RecursionCount和ContentionCount是什么意思?
这个死锁是如何产生的?
------解决方案--------------------
你还得需要Symbol文件吧,Windows自己和你的产品的Symbol都需要设置上才能看到的吧?
------解决方案--------------------
需要Symbol文件
------解决方案--------------------
缺少符号文件
------解决方案--------------------
给你几个网页吧:
http://www.1qidu.com/?action-viewnews-itemid-4755
RecursionCountRecursionCount字段表示那个拥有线程曾经为这个临界区调用EnterCriticalSection的次数。
EntryCount字段表示除那个拥有线程之外的线程曾经为这个临界区调用EnterCriticalSection的次数。
当第一个线程调用EnterCriticalSection例程的时候,临界区的LockCount、RecursionCount、EntryCount和ContentionCount字段的增量都是加1,而且OwningThread变成这个调用者的线程ID。EntryCount和ContentionCount没有增量。
.....
http://hi.baidu.com/piperworldcup/blog/item/e5baf9e7c9446e26b9382091.html
另外从Windbg自己的帮助文档你搜索RecursionCount:
Interpreting Critical Section Fields in Windows XP and Windows 2000
The most important fields of the critical section structure are as follows:
In Microsoft Windows 2000, and Windows XP, the LockCount field indicates the number of times that any thread has called the EnterCriticalSection routine for this critical section, minus one. This field starts at -1 for an unlocked critical section. Each call of EnterCriticalSection increments this value; each call of LeaveCriticalSection decrements it. For example, if LockCount is 5, this critical section is locked, one thread has acquired it, and five additional threads are waiting for this lock.
The RecursionCount field indicates the number of times that the owning thread has called EnterCriticalSection for this critical section.
The EntryCount field indicates the number of times that a thread other than the owning thread has called EnterCriticalSection for this critical section.
我没用Windbg查死锁,但是 曾经用!analyse -v来判断被测产品在第几行代码Crash...