Diese Präsentation wurde erfolgreich gemeldet.
Wir verwenden Ihre LinkedIn Profilangaben und Informationen zu Ihren Aktivitäten, um Anzeigen zu personalisieren und Ihnen relevantere Inhalte anzuzeigen. Sie können Ihre Anzeigeneinstellungen jederzeit ändern.
Anatomy of Filesystems..
Anatomy of HardisksTrack 1                                                   “Platter” – A circular piece of              ...
Anatomy of CommunicationCommunication in Humans:                                                Requirements:             ...
Communicating with your HardiskVarious communication standards exist to talk to our Harddisks: Communication Requirements ...
SCSI Overview  Target                                Host Bus Adapter(HBA)   ID: 0             8 Bit wide wires  Target   ...
SCSI Communication in Action          OS:      CPU: Give me Block 1, from disk0        OS: your        data, ”Hello”      ...
FileSystemsOrganize Scattered Data:                                                   Visible part of Metadata:For FileSys...
FileSystems - Dig DeeperFileSystem Blocks:FileSystem Block                                         Block 0 (4Kb, Block siz...
FileSystems – Contd…Block Groups:                                       Block Group 0         Super        Group Descripto...
FileSystems – Contd…Difference between file and directory Inode: File Inode :                                             ...
FileSystems – Contd…SuperBlock :                 Free Blocks                Free Inodes                     Size          ...
FileSystem in ActionListing Contents of a file:                                                             • Read the ino...
Thank You…   Email: bennojoy@gmail.com      bennojoy@gmail.com
Nächste SlideShare
Wird geladen in …5
×

Anatomy of file_system

  • Loggen Sie sich ein, um Kommentare anzuzeigen.

Anatomy of file_system

  1. 1. Anatomy of Filesystems..
  2. 2. Anatomy of HardisksTrack 1 “Platter” – A circular piece of magnetic material “Tracks” – Platters divided into concentric circles Track 0 Read/Write Head 0 Platter1,track0Read/Write data from Hardisk ? Platter2,track0 Cylinder 0 Read Cylinder 0,head 0, Platter3,track0 sector 0. Disk Controller. CHS Addressing bennojoy@gmail.com Does operations like read, write etc..
  3. 3. Anatomy of CommunicationCommunication in Humans: Requirements: • Speaker/Listener • Voice/Language • Medium: Air • Addressing bennojoy@gmail.com
  4. 4. Communicating with your HardiskVarious communication standards exist to talk to our Harddisks: Communication Requirements SCSI Specification Speaker/Listener Initiator/Target Voice/Language SCSI Commands Medium SCSI Bus Addressing SCSI ID bennojoy@gmail.com
  5. 5. SCSI Overview Target Host Bus Adapter(HBA) ID: 0 8 Bit wide wires Target SCSI Bus Converts: PCI -Bus PCI -> SCSI CPU ID: 1 Initiator Target ID: 7Logical Block Addressing (LBA) – A Data Addressing Standardization: Block 0/1 Block 2/3 Track 0 Track 1 Sector 0 Sector 1 Sector 0 Sector 1SCSI Command bennojoy@gmail.com
  6. 6. SCSI Communication in Action OS: CPU: Give me Block 1, from disk0 OS: your data, ”Hello” CPU HBA: Give me Block 1, From Disk 0 CPU: Your data “Hello” Bus Adapter: Initiator Hey, Disk 0, I Need your attention Thanks, READ LBA 2 for me Ok Bus, You have my attention Converts LBA 2 –> CHS 0/0/1 Target Disk0Ok, Here is LBA 2 Data: “Hello” ID 0 bennojoy@gmail.com
  7. 7. FileSystemsOrganize Scattered Data: Visible part of Metadata:For FileSystems:• Index(TOC) = Metadata• Contents = Data bennojoy@gmail.com
  8. 8. FileSystems - Dig DeeperFileSystem Blocks:FileSystem Block Block 0 (4Kb, Block size)SCSI Block (LBA) Block 0 Block 1 Block … Block 8Disk Block Sector 0 Sector 1 Sector … Sector 8Fileystem layout on Disk: Boot Block Group 0 Block Group… Block Group .. N Block Block 0 Block 1 Block 2 Block 3 Block 4 Block N bennojoy@gmail.com
  9. 9. FileSystems – Contd…Block Groups: Block Group 0 Super Group Descriptor Inode Data Blocks … N Block Blocks.. BlocksInodes :Every file or Directory will have a corresponding Inode, which contains informationcorresponding to the file or directory Entries in an Inode : Inode Block: Owner Inode 1 Mode (permission/Directory/File) 128 bytes TimeStamp Inode 2 Address of 1st Data Block Inode … Address of 2nd Data Block Inode 32 Address of Direct and Indirect Data Block bennojoy@gmail.com
  10. 10. FileSystems – Contd…Difference between file and directory Inode: File Inode : Data Block 22: Owner Hello Mode (File) World ! TimeStamp Data Block 22 Address of 2nd Data Block Address of Direct and Indirect Data Block Directory Inode : Data Block 50: Owner Mode (Directory) “File1” - 32 TimeStamp “File2” - 36 Data Block 50 Address of 2nd Data Block Address of Direct and Indirect Data Block bennojoy@gmail.com
  11. 11. FileSystems – Contd…SuperBlock : Free Blocks Free Inodes Size Block Size etc..Group Descriptor : Block Number of First Inode No of free blocks in group Revisit the FileSystem Layout in Disk: bennojoy@gmail.com
  12. 12. FileSystem in ActionListing Contents of a file: • Read the inode entry of / (Root directory) • The root inode is fixed, inode entry 2 in the first inode block of the first blockgroup Test Inode Mode (Directory) “a” – Inode(5) Data Block 2 Root Inode Mode (Directory) A Inode “Test” – Inode(3) “hello world” Mode (File) “Bin” – Inode(4) Data Block 1 Data Block 3Inode1 Inode2 Inode3 Inode4 Inode5 Block1 Block2 Block3 Block4 Block5 bennojoy@gmail.com
  13. 13. Thank You… Email: bennojoy@gmail.com bennojoy@gmail.com

×