TheHingineer

  • Operating System


  • OS Part-1

  • OS Part-2

  • OS Part-3

  • OS Part-4

  • OS Part-5

  • File System in Linux & Windows

    1. File System Kya Hota Hai?

    File System ek method hota hai jisme OS (Operating System) data ko store, organize aur retrieve karta hai. Ye files ko folders me arrange karta hai aur metadata (file size, type, permissions) store karta hai.

    🔹 Example: Jab aap ek document save karte ho, toh file system decide karta hai ki wo hard drive ke kis part me store hoga aur jab zaroorat ho toh kaise access kiya jayega.

    📌 File System Ke Important Functions:

    ✅ Storage Management – Data ko efficiently store karna.
    ✅ File Naming – Different file extensions aur names support karna.
    ✅ Security & Permissions – User access control manage karna.
    ✅ Data Organization – Folders aur directories ka use karke structured storage provide karna.


    2. Windows ka File System

    Windows NTFS, FAT32 aur exFAT file systems use karta hai.

    🔹 NTFS (New Technology File System)

    ✅ Bade file sizes ko support karta hai (16 Exabytes tak).
    ✅ Security aur encryption provide karta hai.
    ✅ Journaling feature hota hai jo data corruption ko rokta hai.
    ✅ Compression & Quotas ka support hota hai jo storage management me help karta hai.

    🔹 Example: Windows Me File Storage Kaise Hota Hai?

    C:\Users\John\Documents\report.docx

    Yahaan:

    • C:\ → Root directory hai.

    • Users\John\Documents\ → Folder hierarchy hai.

    • report.docx → File ka naam hai.

    🔹 FAT32 (File Allocation Table 32-bit)

    ✔ Almost sabhi devices ke saath compatible hai.
    ✔ 4GB se badi files store nahi kar sakta.
    ✔ Old systems aur USB drives me use hota hai.

    🔹 exFAT (Extended File Allocation Table)

    ✔ External drives ke liye best hai.
    ✔ FAT32 se better hai kyunki ye badi files support karta hai.
    ✔ Windows aur macOS dono me work karta hai.


    3. Linux ka File System

    Linux me multiple file systems available hote hain jaise EXT4, XFS, Btrfs.

    🔹 EXT4 (Fourth Extended File System)

    ✅ Most Linux distributions ka default file system hai.
    ✅ Journaling feature hota hai jo data corruption se bachaata hai.
    ✅ 16TB tak ki files support karta hai.
    ✅ Performance FAT32 aur NTFS se better hai.

    🔹 Example: Linux Me File Storage Kaise Hota Hai?

    /home/user/Documents/report.docx

    Yahaan:

    • / → Root directory hai.

    • /home/user/Documents/ → Folder hierarchy hai.

    • report.docx → File ka naam hai.

    🔹 XFS (High-Performance File System)

    ✔ Large data processing ke liye best hai.
    ✔ Mostly enterprise servers me use hota hai.

    🔹 Btrfs (B-Tree File System)

    ✔ Snapshots aur backup management support karta hai.
    ✔ Data integrity aur error checking ke liye bana hai.


    4. Windows vs Linux File Systems (Differences)

    Feature Windows (NTFS) Linux (EXT4)
    Speed Moderate Fast
    Security Encryption & permissions Advanced permissions (Read, Write, Execute)
    Journaling Yes Yes
    File Naming Case-insensitive (File.txt = file.txt) Case-sensitive (File.txtfile.txt)
    Compatibility Works mainly with Windows Linux me work karta hai, Windows par bhi special tools se access ho sakta hai
    Performance General users ke liye acha hai Multi-user environments ke liye optimized hai

    5. File Access Kaise Hota Hai?

    🔹 Windows Me File Access (NTFS Permissions)

    • Read (R) – File read kar sakte ho.

    • Write (W) – File me changes kar sakte ho.

    • Execute (X) – Executable files run kar sakte ho.

    🔹 Linux Me File Access (EXT4 Permissions)
    Linux me file permissions 3 users ke basis par set hoti hain:
    1️⃣ Owner (file create karne wala user)
    2️⃣ Group (jo users us file group me hote hain)
    3️⃣ Others (baaki sab log jo owner ya group me nahi hain)

    Linux me permissions 3-number system me define hoti hain:

    rwxr-xr--
    • rwx (Owner → Read, Write, Execute kar sakta hai)

    • r-x (Group → Read aur Execute kar sakta hai)

    • r-- (Others → Sirf Read kar sakte hain)

    🔹 Example: Linux Me File Permissions Change Karna

    chmod 755 file.txt
    • Owner (7) → Full access (Read, Write, Execute)

    • Group (5) → Read & Execute

    • Others (5) → Read-only


    6. Conclusion

    ✔ Windows NTFS, FAT32 aur exFAT support karta hai, jabki Linux EXT4, XFS aur Btrfs use karta hai.
    ✔ NTFS security aur encryption features provide karta hai, jabki EXT4 performance aur reliability ke liye best hai.
    ✔ Windows ka file system case-insensitive hota hai (file.txt = File.txt), jabki Linux case-sensitive hota hai (file.txtFile.txt).
    ✔ Linux file system advanced file permissions aur flexibility provide karta hai.

    Scroll to Top