• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 4053
  • Last Modified:

How to find what process is locking a file in Linux

How can I determine what process is locking a file? Is there a filemon for Linux?
0
eocallaghan
Asked:
eocallaghan
2 Solutions
 
msklizmantasCommented:
hello,

try to use lsof utility - it will show you open files and who is using them.

best regards,

m
0
 
http:// thevpn.guruCommented:
adding to the previous comment

lsof | grep filename to get the exact entry
0
 
ibu1Commented:
#lsof -n |more
0
 
omarfaridCommented:
Hi,

Use fuser command. Please see man page:

http://linux.about.com/library/cmd/blcmdl1_fuser.htm
0

Featured Post

Microsoft Certification Exam 74-409

VeeamĀ® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now