disk structures
DESCRIPTION
Disk Structures. Formatting a Disk. Two parts to formatting a disk: Low-level (physical) formatting High level (logical) formatting Low-level (physical) formatting: Sequentially numbers tracks and sectors Identifies each track and sector Disk is physically prepared to hold data - PowerPoint PPT PresentationTRANSCRIPT
Disk Structures
CTEC 110 2
Formatting a Disk
Two parts to formatting a disk: Low-level (physical) formatting High level (logical) formatting
Low-level (physical) formatting: Sequentially numbers tracks and sectors Identifies each track and sector Disk is physically prepared to hold data
High-level (logical) formatting: Determines how OS uses a disk Builds structure to keep track of location of files Done so files can be stored and retrieved
Disk Structures (31 slides)
CTEC 110 3
Formatting a Disk
Windows XP Professional monitors status of all disk data sectors
One or more sectors are combined into logical units called clusters or allocation units
Cluster (allocation unit): Smallest unit that OS can work with
Cluster overhang: Wasted space on the disk
Disk Structures (31 slides)
CTEC 110 4
Master Boot Record & Boot Sector
Disk Structures (31 slides)
CTEC 110 5
Master Boot Record & Boot Sector
Master boot record (MBR): First part of hard disk Locates bootable partition of hard disk and gives
control over to it
Boot sector: First sector on logical drive Has table of drive’s characteristics Has bootstrap loader program
All disks (including non-system disks) have a boot sector
Disk Structures (31 slides)
CTEC 110 6
Master Boot Record & Boot Sector
FAT non-system error messages: Non-system disk or disk error Replace disk and press any key when ready
NTFS non-system error messages: Invalid partition table Error loading operating system Missing operating system
Floppy disk non-system error messages: NTLDR is missing Press any key to restart
Windows uses boot sector to identify the type of disk.
Disk Structures (31 slides)
CTEC 110 7
FAT16, VFAT, and FAT32
Disk Structures (31 slides)
CTEC 110 8
FAT15, VFAT & FAT32
FAT ‘s formatting program creates: Boot record File Allocation Table (2 copies) Root directory
Logical Structure of a Disk
Disk Structures (31 slides)
CTEC 110 9
FAT15, VFAT & FAT32
FAT is a map of disk’s data clusters FAT number indicates status of cluster
(Numbers in FAT .. link clusters that belong to same file)
Cluster Size and Disk Size
Disk SizeNumber of Sectorsin a Cluster
Cluster Sizein Bytes
Cluster Sizein KB
3 1/2-inch 1.44 MB 1 Sector 512 1/2 KB
3 1/2-inch 2.88 MB 2 sectors 1,024 1KB
33 MB-64 MB 2 sectors 1,024 1KB
65 MB-128 MB 4 sectors 2,048 2KB
129 MB-256 MB 8 sectors 4,096 4KB
257 MB-512 MB 16 sectors 8,192 8KB
513 MB-1,024 MB 32 sectors 16,384 16KB
1,025 MB-2,048 MB 64 sectors 32,768 32KB
Disk Structures (31 slides)
CTEC 110 10
FAT15, VFAT & FAT32
FAT essential for : Managing data Following trail of clusters that make up a file
VFAT maintains backwards compatibility and accommodates long file names.
FAT32: Enhancement of FAT file system Introduced to overcome limitations of VFAT Does not apply to floppy drives
Disk Structures (31 slides)
CTEC 110 11
FAT15, VFAT & FAT32
Comparison of FAT and FAT32
Disk Structures (31 slides)
CTEC 110 12
FAT15, VFAT & FAT32
FAT32: Movable Root Directory
Can be located anywhere on hard disk Can use backup copy of FAT Internal backup copy of some critical FAT data structures Entries in Root Directory limited
With smaller clusters: Table smaller Takes less time to locate/access file Increases wasted disk space from cluster overhang
FAT32 is best for many small filesFAT is best for mostly large files
Disk Structures (31 slides)
CTEC 110 13
The Root Directory
Disk Structures (31 slides)
CTEC 110 14
The Root Diretory
Root Directory: Table that records information about
each file on the disk Changes in root directory table make
Windows XP Professional compatible with older Windows and DOS programs
Root directory tells what is on the disk
Disk Structures (31 slides)
CTEC 110 15
The FAT and the Root Directory
Disk Structures (31 slides)
CTEC 110 16
The FAT and the Root Directory
FAT tells where data is on the disk Number is FAT points to next cluster that
holds data in file EOF (end-of-file) marker indicates there is
no more data in file
Disk Structures (31 slides)
CTEC 110 17
The FAT and the Root Directory
The Root Directory and FAT
Disk Structures (31 slides)
CTEC 110 18
The Data Portion or the Files Area
Disk Structures (31 slides)
CTEC 110 19
The Data Portion or the Files Area
Largest part of disk is used for storing files Space is allocated to files on an as-
needed basis
A file is written to a disk in: Contiguous clusters or Non-contiguous clusters
Disk Structures (31 slides)
CTEC 110 20
Understanding the FAT and the Root Directory
Disk Structures (31 slides)
CTEC 110 21
Understanding the FAT and the Root Directory
Storing Files
Disk Structures (31 slides)
CTEC 110 22
NTFS
Disk Structures (31 slides)
NTFS
File system used determines OS advanced features available to user
For disk security, performance, and efficiency use NTFS file system
Advantages of NTFS: Secure file system Efficient storage of data Faster file access Better data recovery Can compress files/assign disk quotas Encryption of files
CTEC 110 23Disk Structures (31 slides)
CTEC 110 24
Clusters and NTFS
Disk Structures (31 slides)
CTEC 110 25
Clusters and NTFSNTFS: Uses FAT cluster scheme for allocating data Has less overhead
NTFS Cluster Size
Partition Size Cluster Size in Bytes Sectors in a Cluster7 MB-512 MB 512 1513 MB-1,024 MB 1,024 (1 KB) 21,025 MB-2 GB 2,048 (2 KB) 42 GB-2 TB* 4.096 (4 KB) 8*A terabyte is 1,099,511,627,776 bytes or 1,024 gigabytes and is abbreviated as TB
Disk Structures (31 slides)
CTEC 110 26
Clusters and NTFS
Structure of an NTFS Volume
Disk Structures (31 slides)
CTEC 110 27
Master File Table (MFT)
Disk Structures (31 slides)
NTFS Master File Table (MFT)
Master File Table (MFT): Database of all files in system Used by NTFS to track all files and directories
in a volume Dynamic
CTEC 110 28Disk Structures (31 slides)
NTFS Master File Table (MFT)
MFT is different from FAT:MFT: Adds security descriptor attribute to file system Data in file considered to be attribute of file
Allows fast access to files Eliminates file fragmentation
Attribute stored in MFT considered resident attribute Any resident forced out to an extent is nonresident attribute
Folders treated as files in NTFS: Small folder – Index Root attribute Folder entries will fit into MFT – new extent nonresident attribute
called index buffer
CTEC 110 29Disk Structures (31 slides)
CTEC 110 30
Deciding on a File System
Disk Structures (31 slides)
Deciding on a File System
Formatting:
Floppy disk – always FAT file system
Hard disk – you decideCan convert FAT to FAT32/NTFSCannot convert FAT32/NTFS to FAT
CTEC 110 31Disk Structures (31 slides)