Persistent Indexing for Flat Directory Lookup Speed
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Flat directory formats suffer from slow lookup operations due to the lack of indexing, which also affects free space management, leading to inefficiencies in file system access and storage operations.
Innovation Solution
Implementing persistent indexing and free space management through the creation of a separate index file using a B+ format, which stores mapping information such as hash values and location cookies, and maintaining free space lookup link lists to optimize disk reads and storage allocation.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Device complexity
If a flat directory format is used to store all blocks at the same level, then the directory structure is simple and easy to implement, but lookup operations become very slow as the directory size increases
Solution Approach 1:
The patent divides the flat directory into multiple blocks organized in a tree structure with index blocks at different levels. Each index block contains entries pointing to child blocks, creating a hierarchical segmentation that enables efficient lookup by progressively narrowing down the search space from root to leaf blocks.
2Ease of manufacture
If all directory blocks are stored on disk without indexing, then storage is simple, but free slot lookup operations require reading all blocks resulting in inefficiency
Solution Approach 1:
The patent pre-organizes directory blocks into a tree structure with index blocks that maintain information about free slots and block assignments. This preliminary organization allows free slot lookup operations to quickly identify available space without scanning all directory blocks, as the index blocks already contain the necessary metadata.
3Speed
If a hierarchical directory structure with index blocks is implemented, then lookup operations become fast, but the device complexity and structure become more complicated
Solution Approach 1:
The patent introduces a hierarchical dimension to the flat directory by creating multiple levels of index blocks. Each index block level adds a dimension to the lookup process, transforming a linear scan through all blocks into a multi-level tree traversal that dramatically reduces the number of blocks that need to be examined.
4Loss of time
If persistent indexing is implemented with a separate index file, then lookup operations achieve logarithmic time performance, but the system requires additional files and management overhead
Solution Approach 1:
The patent introduces an index file as an intermediary between the directory blocks and the lookup operations. This separate index file contains hashed keys and location information that mediates the search process, allowing the system to achieve logarithmic lookup time by first consulting the index file to locate the relevant directory blocks before performing the actual filename search.
Data Source
AI summary
Methods, non-transitory computer readable media, computing devices and systems for persistent indexing and space management for flat directory include creating, using at least one of said at least one processors, an index file to store mapping information, computing, using at least one of said at least one processor, a hash based on a lookup filename, searching, using at least one of said at least one processor, the index file to find all matching directory cookies based on the computed hash, selecting, using at least one of said at least one processor, the directory entity associated with the lookup filename from among the matched directory cookies, and returning, using at least one of said at least one processor, the determined directory entity.


