Locked files - who has it locked?

Locked files - who has it locked?

Post by Brian Vett » Fri, 04 Oct 1991 06:14:04



I am using advisory locks on SUNOS 4.1.1 and I find that sometimes I
have lockf calls failing to acquire locks when I don't believe that
any process has the file opened or locked.  This seems to happen when
the file is on a NFS file system and the process that previously have had
the lock terminated.

My question:  When I find myself in this state, is there anyway to tell
which process owns the lock (if any)?  The crash documents don't discuss
this and I don't have the sources to peek around kernel data structures
to figure out what's going on.

Or, is there well known problems with Sun's lock manager (lockd) that
is the culprit.  After killing off lockd and statd on all machines
concerned, and waiting 20 minutes, the lock mysteriously went away.

If you can help, please respond by email.

Thanks,

Brian Vetter

 
 
 

1. netscape rpm from compaq + my box = lock lock lock

  I've been having some wierd lockups with the netscape rpm that compaq
released for linux alpha. I'm running a pc164 with two tulip cards in it,
with pppoe. Every once in awhile, I'll crank up netscape and look at a
site only to have my machine lock up amazingly tight. Has anyone seen this
before?

--
---
Eric Jones                    

  If you can't figure out what to remove in the above addy to email me, then
you are a cephalopod.
  Here's a few email addresses to help out the spammers:        

IS YOUR INTERNET BROKED? DOES EMAILING THE NETSCAPE SYSOP NOT FIX IT?

2. Modem setup, internal vs external

3. Modem TX and RX status via Num Lock-Caps Lock-Scroll Lock

4. NFS refuses to export

5. More mail file locking questions (lockf, NFS, /var/spool/mail/*.lock)

6. mstats() from malloc.h

7. "Can't read lock file /tmp/.X0-lock"

8. austria groups may more of

9. modem locked but I can't find the lock file

10. Apache: Cannot open lock file: /usr/logs/httpd.lock.10064

11. how to remove a lock from a locked file?

12. Fatal Server Error: Could not create lock file in /tmp/.tX0-lock???

13. unable to lock mailbox: no locks available