1

This question already has an answer here:

How is the path of a directory retrieved in UNIX filesystems? Since directories are pointing to subdirectories it seems like the path need to be set together from the parent and parent parents etc.

Is this how it's done or are the paths stored somewhere in the inodes?

marked as duplicate by roaima, Community Jun 5 '16 at 16:00

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 4
    No, the path is not stored in the inode. That wouldn't make much sense because an inode can have multiple hard links which could be placed in multiple different directories, so there isn't a single path that points to the inode. Each directory contains a list of its subdirectories and contained files, and a path is constructed by appending the names of all these path components together. – Martin von Wittich Jun 5 '16 at 15:06

Browse other questions tagged or ask your own question.