Abstract:This paper introduces a method to detect operating system deadlock. The method consists of three stages: (1) finding the lock-holders by detecting whether the locks and unlocks are paired. (2) finding the lock-waiters by filtering the abnormal process. (3) the method will occur deadlock warning if there is a cycle in the waits-for graph. The results show that the method has only 1% influence to the performance, and does not need to modify Linux kernel and detected program source code.