1. Local File System (LFS) :
The basic file system of Linux operating system is termed as Local file system. It stores any data file as it is in single copy.
It stores data files in Tree format. Here, any user can access data files directly. LFS does not Replicate the data blocks. It always used for storing and processing personal data(small data).
2. Distributed File System (DFS) :
When we need to store and process a large data file (approx 1 TB size file at least), the Local file system of Operating system is not appropriate. In such cases we use Distributed File system. It can be created on any Linux operating system with Hadoop. DFS stores any data file by dividing it into several blocks.
This file system works on Master-Slave format where Master is NameNode and DataNodes are the slaves. All the blocks of a Data file is stored into different DataNodes and the location is only known by NameNode. Every Data Block is replicated into different Datanodes to avoid data loss when any datanode fails. In DFS Data files are directly not accessible to any user because only NameNode knows where the Data blocks of Data file are stored.
Difference between Local File System (LFS) and Distributed File System (DFS) :
|Local File System||Distributed File System|
|LFS stores data as a single block.||DFS divides data as multiple blocks and stores it into different DataNodes.|
|LFS uses Tree format to store Data.||DFS provides Master-Slave architecture for Data storage.|
|Data retrieval in LFS is slow.||Data retrieval in DFS is fast.|
|It is not reliable because LFS data does not replicate the Data files.||It is reliable because in DFS data blocks are replicated into different DataNodes.|
|LFS is cheaper because it does not needs extra memory for storing any data file.||DFS is expensive because it needs extra memory to replicate the same data blocks.|
|Files can be accessed directly in LFS.||Files can not be accessed directly in DFS because the actual location of data blocks are only known by NameNode.|
|LFS is not appropriate for analysis of very big file of data because it needs large time to process.||DFS is appropriate for analysis of big file of data because it needs less amount of time to process as compare to Local file system.|
|LFS is less complex than DFS.||DFS is more complex than LFS.|
Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.
- Difference between File System and DBMS
- Difference between FAT32, exFAT, and NTFS File System
- File System Implementation in Operating System
- Unix File System
- Network File System (NFS)
- Various terms in File System
- Protection in File System
- Understanding File System
- File Systems in Operating System
- Levels in a File Management System
- File Access Methods in Operating System
- Compare file system in Windows and Linux
- File System Consistency Checker (FSCK)
- Difference between Management Information System (MIS) and Decision Support System (DSS)
- Mutual exclusion in distributed system
- Logical Clock in Distributed System
- Hierarchical Deadlock Detection in Distributed System
- Lamport's Algorithm for Mutual Exclusion in Distributed System
- Maekawa’s Algorithm for Mutual Exclusion in Distributed System
- Ricart–Agrawala Algorithm in Mutual Exclusion in Distributed System
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.