Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

namei: add page #2427

Merged
merged 3 commits into from
Oct 12, 2018
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions pages/linux/namei.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# namei

> Follows a pathname (which can be a symbolic link) until a terminal point is found (a file/directory/char device etc).
owenvoke marked this conversation as resolved.
Show resolved Hide resolved
> This program is useful for finding "too many levels of symbolic links" problems.

- Resolve the pathnames specified as the argument parameters:

`namei {{/path/to/a}} {{/path/to/b}} {{/path/to/c}}`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the prefixing slash from each path (i.e. {{path/to/...}})


- Display the results in a long-listing format:

`namei --long {{/path/to/a}} {{/path/to/b}} {{/path/to/c}}`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the prefixing slash from each path


- Show the mode bits of each file type in the style of `ls`:

`namei --modes {{/path/to/a}} {{/path/to/b}} {{/path/to/c}}`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the prefixing slash from each path


- Show owner and group name of each file:

`namei --owners {{/path/to/a}} {{/path/to/b}} {{/path/to/c}}`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the prefixing slash from each path


- Don't follow symlinks while resolving:

`namei --nosymlinks {{/path/to/a}} {{/path/to/b}} {{/path/to/c}}`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the prefixing slash from each path

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch. Done!