How to read /proc/locks in safe mode?

Dario Lesca d.lesca at solinos.it
Fri Jul 15 09:26:10 UTC 2011


Il giorno mar, 12/07/2011 alle 14.13 +0200, Dario Lesca ha scritto: 
> Hi, how to I can read in safe mode, from bash, the content
> of /proc/locks?
> 
> On my system I have more than 7000/9000 line into /proc/locks and if I
> read it with awk (or cat or grep or cp) the file change during the read
> and my input is undefined and is not processable (see attach).
> 
> My target is read if a process lock a specific files (through its
> i-node)
> 
> Someone can suggest me some kind of solution?

Then, there are not solutions for my problem?

Or my question is not clear?

Via bash, what is the best method for know if a process lock a specific
files? 

Thanks, (and sorry for my bad english)

-- 
Dario Lesca <d.lesca at solinos.it>



More information about the devel mailing list