namei
follow a pathname until a terminal point is found
namei [options] pathname…
For pathnames including symlinks, files, directories, …), follows
each until an endpoint is found (a file, a directory, a device node, etc).
For a symbolic link, it shows the link, and starts following it, indenting the output to show the context.
To identify the file type found:
f the pathname currently being resolved
d directory
l symbolic link (both the link and its contents are output)
s socket
b block device
c character device
p FIFO (named pipe)
- regular file
? an error
Outputs a message when the maximum number of symbolic links this system can have has been exceeded.
OPTIONS
-l --long Use the long listing format (same as -m -o -v).
lis | | -l --long Use the long listing form
36b/c/pgrmrs > namei www/docs/namei.1.html # default
f: www/docs/namei.1.html
l www -> public_html
d public_html
d docs
- namei.1.html
36b/c/pgrmrs > namei public_html/docs/namei.1.html
f: public_html/docs/namei.1.html
d public_html
docs
- namei.1.html
36b/c/pgrmrs > namei -l public_html/docs/namei.1.html
f: public_html/docs/namei.1.html
drwxr-xr-xrwss.com pgrmrs public_html
drwxr-xr-xrwss.com pgrmrs docs
namei -m public_html/docs/namei.1.html
f: public_html/docs/namei.1.html
drwxr-xr-x public_html
drwxr-xr-x docs
-rw-r--r-- namei.1.html
36b/c/pgrmrs > namei -o public_html/docs/namei.1.html
f: public_html/docs/namei.1.html
drwss.com pgrmrs public_html
drwss.com pgrmrs docs
-rwss.com pgrmrs namei.1.html
namei -x public_html/docs/namei.1.html
f: public_html/docs/namei.1.html
d public_html
d docs
- namei.1.html
-m --modes Show the mode in the style of ls, for example ,code>rwxr-xr-x'.
| -o --owners Show owner and group
| -v --vertical Vertically align the modes and owners.
| -n --nosymlinks No symlinks are followed .
| -x --mountpoints Show mountpoint directories with a <,b>D' rather than a 'd'.
| -h --help Output help text and exit.
| | --version | Output version information and exit.
| | | | | | | | | |
useful for finding "too many levels of symbolic links" problems.
AUTHOR
The original namei program was written by Roger Southwick rogers@amadeus.wr.tek.com>.
The program was re-written by Karel Zak kzak@redhat.com>..
AVAILABILITY
The namei command is part of the util-linux package and is available from ftp://ftp.kernel.org/pub/linux/utils/util-linux/.