Reverse Pathname Lookup via Parent Inode Identifier

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In file systems, particularly in UNIX environments, determining the filename of a file from its inode identifier is challenging due to the absence of filename information in the inode, leading to inefficient reverse pathname lookups that require scanning directories, which can be time-consuming.

Innovation Solution

Storing the parent directory inode identifier in the file's inode allows for the generation of pathnames by searching the parent directory for the file's inode identifier, enabling quick identification of the filename and potentially multiple pathnames if multiple links exist, with additional parent directory identifiers stored in an extended area for new files and links.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Device complexity

If the filename is not stored in the inode, then the inode structure remains simple and efficient, but the reverse pathname lookup becomes time-consuming requiring directory scanning

Engineering Contradiction:
Improveinode structureVSAvoidreverse pathname lookup time
Core Design Contradiction:
Device complexityVSLoss of time

Solution Approach 1:

The parent directory inode identifier is stored in the file's inode during file creation or link establishment, performing the necessary lookup preparation in advance. This preliminary action eliminates the need for time-consuming directory scanning during reverse pathname lookup operations.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The parent directory inode identifier acts as an intermediary element that bridges the file inode and the parent directory. By storing this intermediate reference in the file's inode, the system can quickly navigate to the parent directory without scanning all directories, thus resolving the time loss problem.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Loss of time

If parent directory inode identifier is stored in the file's inode, then reverse pathname lookup time is reduced, but the inode structure becomes more complex

Engineering Contradiction:
Improvereverse pathname lookup timeVSAvoidinode structure
Core Design Contradiction:
Loss of timeVSDevice complexity

Solution Approach 1:

The parent directory inode identifier is stored only when needed (when a link is created or during file operations), rather than being present in all inodes. This selective storage approach minimizes the increase in inode structure complexity while still providing the performance benefit where required.

Inventive Principle:
Principle #3Local quality

Solution Approach 2:

The parent directory inode identifier is pre-stored in the inode during file creation or link establishment, so that when reverse pathname lookup is needed, the information is already available. This preliminary action reduces lookup time without requiring complex dynamic structures.

Inventive Principle:
Principle #10Preliminary action

3Adaptability or versatility

If multiple parent directory identifiers are stored for multiple links, then all pathnames can be retrieved, but the inode size increases

Engineering Contradiction:
Improvepathname retrieval capabilityVSAvoidinode size
Core Design Contradiction:
Adaptability or versatilityVSQuantity of substance

Solution Approach 1:

The inode stores parent directory identifiers only for the necessary number of links. When a file has multiple links, only the required parent directory identifiers are stored, avoiding unnecessary storage space. This partial action approach balances versatility with space efficiency.

Inventive Principle:
Principle #16Partial or excessive action

Solution Approach 2:

When a link is removed, the corresponding parent directory identifier is removed from the inode. This dynamic management ensures that the inode only contains relevant parent directory identifiers, minimizing storage space while maintaining the ability to retrieve all current pathnames.

Inventive Principle:
Principle #34Discarding and recovering

Data Source

PatentUS7752226B1Reverse pathname lookup by inode identifier
Publication Date: 2010.07.06 ARCTERA US LLC
  • US7752226B1 patent drawing
  • US7752226B1 patent drawing
  • US7752226B1 patent drawing

AI summary

Information identifying the inode of the parent directory of a file may be stored in that file's inode. A reverse pathname lookup from the file's inode identifier may be performed by reading a parent directory inode identifier of the file's parent directory from the file's inode and using the parent directory inode identifier to generate a pathname for the file. Generating the pathname may involve identifying the filename of the file by searching the parent directory identified by the parent inode identifier for the file's filename. A file's inode may include more than one parent directory inode identifier.