Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is it possible to see if a file is locked or not?

Status
Not open for further replies.

NeilFawcett

Programmer
Mar 19, 2004
30
0
0
GB
Can you see if someone has a file locked (via FLOCK)?

I don't necessarily want to read the data from a file, just see if it is locked or not by someone.
 
Depending on the type of lock (exclusive) you won't be able to get a lock on the file

HTH
--Paul
 
I don't want to get a lock of the file(s). I want to see if they are locked.
 
if you're using UNIX, try the fuser command.

Mike

Want to get great answers to your Tek-Tips questions? Have a look at faq219-2884

It's like this; even samurai have teddy bears, and even teddy bears get drunk.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top