File System Hierarchy क्या है?
File System Hierarchy वह structure है जिसमें Linux/UNIX system में files और directories को tree (पेड़) की तरह organize किया जाता है।
मतलब:
सारी files एक root directory से शुरू होकर अलग-अलग folders में arranged होती हैं।
Basic Concept
- Structure tree जैसा होता है
- सबसे ऊपर Root Directory होती है
- उसके अंदर sub-directories और files होती हैं
- हर file का एक path होता है
Root Directory
- Root Directory को
/से represent किया जाता है - यह पूरे file system की top level directory होती है
Example:
/home/user/file.txt
Important Directories in Linux
/home
- Users की personal files store होती हैं
/root
- Administrator (root user) की directory
/bin
- Basic commands store होते हैं
- जैसे: ls, cp, mv
/etc
- System configuration files होती हैं
/dev
- Devices की files (keyboard, disk आदि)
/tmp
- Temporary files store होती हैं
/usr
- User programs और libraries
/var
- Variable data (logs, cache आदि)
Path in File System
Path वह address होता है जिससे file को locate किया जाता है।
Types of Path
- Absolute Path
- Root (
/) से शुरू होता है
Example:
/home/user/file.txt
- Relative Path
- Current directory से start होता है
Example:
user/file.txt
Features of File System Hierarchy
- Organized structure
- Easy navigation
- Efficient file management
- Multi-user support
Example
मान लो:
File /home/student/notes.txt में है
तो:
- Root → /
- home → folder
- student → sub-folder
- notes.txt → file
Short Conclusion
File System Hierarchy एक tree structure है जिसमें Linux/UNIX में files और directories को organize किया जाता है। यह root directory से शुरू होता है और different folders में data को व्यवस्थित करता है।