In article <20040112230102.GM18439@jpradley.jpr.com>,
Jean-Pierre Radley <jpr@jpr.com> wrote:
>Brian K. White typed (on Mon, Jan 12, 2004 at 01:47:24PM -0800):
>| lslk outputs inode numbers for file locks.
>|
>| Is there a faster way than this find command to find out the filename
>| associated with the inode numbers?
>| In the following session, lslk returns immediately, but find takes 20
>| seconds or so before in prints that filename, and then continues to
>| run for an unknown time longer scanning the rest of the disk(s). (I
>| hit delete after another 30 seconds)
>|
>| # lslk |grep 177094
>| rclerk 3972 1,43 177094 1280448 w 0 1022596 0 0 1022599
>| /dev/u (/u)
>| dclerk 8704 1,43 177094 1280448 w 0 1013704 0 0 1013707
>| /dev/u (/u)
>| dclerk 12712 1,43 177094 1280448 w 0 422386 0 0 422389
>| /dev/u (/u)
>| dclerk 22161 1,43 177094 1280448 w 0 391264 0 0 391267
>| /dev/u (/u)
>| dclerk 23056 1,43 177094 1280448 w 0 822526 0 0 822529
>| /dev/u (/u)
>| dclerk 24197 1,43 177094 1280448 w 0 57814 0 0 57817
>| /dev/u (/u)
>| dclerk 26499 1,43 177094 1280448 w 0 791404 0 0 791407
>| /dev/u (/u)
>| rclerk 27410 1,43 177094 1280448 w 0 1240450 0 0 1240453
>| /dev/u (/u)
>| # find / -inum 177094 -print
>| /u/appl/filepro/3disp/keygi
>
>'find' would have returned sooner if you had an inkling to search just one
>filesystem (/u) instead of all of them (/).
>
>BTW: '-print' has been totally unecessary for the find command for
>many years -- it's the default action.
Isn't this what ncheck is for?
LER
>
>--
>JP
--
Larry Rosenman
http://www.lerctr.org/~ler
Phone: +1 972-414-9812 E-Mail:
ler@lerctr.org
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749