[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]

detecting open files

i was trying to solve an earlier query on this list about finding how may times a file is opened. as this thing is stored somewhere in 
kernel, i tried writing a kernel module for it.  i open a file with filp_name & then saw the File--->Dentry--->count . but it shows only the 
number of times the file is opened in kernel mode. i mean i didn't closed the file rmmod the module. insmod it again and the count 
was +1 . opening same file somewhere else like vi  didn't had any effect.  is the data structure i am searching not correct.  i also tried 
various field in  inode struct pointed by dentry struct of that file, but no use.  ??

reply soon

|) (- (- p /\ k

have a nice day
ICQ 30662394