lkml.org 
[lkml]   [1999]   [Jan]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: ext2 tool
Hi Martijn.

>> Is there any tool that gives the corresponding filename for every
>> inode for ext2 file system?

Create /usr/local/bin/ilist with mode 755 and the following contents:

Q> #!/bin/bash
Q> if [ $# -eq 0 ]; then
Q> echo "Usage: `basename $0` dir..."
Q> exit 255
Q> fi
Q> for DIR do
Q> echo "Directory: $DIR"
Q> ls -il `find $DIR`
Q> echo
Q> done
Q> exit 0

When you've done, run it, specifying the mount point of the relevant
file system as a parameter. It doesn't care what type of file system
you point it at, it'll still work...

>> It should print out the inode number, the file name with entire
>> path and tell the kind of inode it is.

All of that and more is included in the output.

Best wishes from Riley.

---
* ftp://ftp.MemAlpha.cx/pub/rhw/Linux
* http://www.MemAlpha.cx/~rhw/kernel.versions.html


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:49    [W:0.038 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site