
Guide to operating systems 4th edition pdf download romsho - abstract thinking
Guide to Operating Systems, 4th ed.
Presentation on theme: "Guide to Operating Systems, 4th ed."— Presentation transcript:
1 Guide to Operating Systems, 4th ed.
Chapter 4: File Systems
2 Objectives List the basic functions common to all file systems
Explain the file systems used by Windows XP, Windows Server 2003, Windows Vista, Windows Server 2008, and Windows 7 (FAT16, FAT32, FAT64, and NTFS)Discuss the file systems used by UNIX and Linux systems, including ufs and extExplain the Mac OS X Extended (HFS+) file system including new features added in Mac OS X version 10.6 LeopardGuide to Operating Systems, 4th ed.2
3 Understanding the File System Functions
All information stored on a computer’s hard disk is managed, stored, and retrieved through a file systemThe file system allocates locations on a disk for storage and it keeps a record of where specific information is keptSome file systems also implement recovery procedures when a disk area is damaged or when the OS goes downThe overall purpose of a file system is to create a structure for filing dataA file is a set of data that is grouped in some logical manner, assigned a name, and stored on the diskGuide to Operating Systems, 4th ed.
4 Understanding File System Functions
File systems used by operating systems perform the following general tasks:Partition and format disks to store and retrieve informationEnable files to be organized through directories and foldersEstablish file-naming conventionsProvide utilities to maintain and manage the file system and storage mediaProvide for file and data integrityEnable error recovery or preventionSecure the information in filesGuide to Operating Systems, 4th ed.
5 Understanding File System Functions
Directory or folder – organizational structure that contains files and may additionally contain subdirectories (or subfolders)Directories may store the following informationDate and time the directory or file was createdDate and time the directory or file was last modifiedDate and time when the directory or file was last accessedDirectory or file sizeDirectory or file attributes, such as security information, or if the directory or file was backed upIf the information in a directory or file is compressed or encryptedGuide to Operating Systems, 4th ed.
6 Designing a Directory Structure
A chaotic file structure:makes it difficult to run or remove programsMakes it difficult to determine the most current versionsMakes users spend unproductive time looking for specific filesSome users keep most of their files in the computer’s primary level or root directory (root folder)Some programs use an automated setup that suggests folders for new programsExample – creating new subfolders under the Program Files folderTo avoid chaos, design the file and folder structure from the start (especially on servers)Guide to Operating Systems, 4th ed.
7 Designing a Directory Structure
Consider following some general practices:Root folder should not be cluttered with files or too many directories/foldersEach software application should have its own folder/subfolderSimilar information should be grouped (example: accounting systems or office productivity software)Operating system files should be kept separate and protectedDirectories and folders should have names that clearly reflect their purposes (a folder named “Shared” would contain documents that can be shared by many users)Guide to Operating Systems, 4th ed.
8 Designing a Directory Structure
Sample folder structure for a Windows-based systemGuide to Operating Systems, 4th ed.
9 Disk Storage BasicsHard disks arrive from manufacturer with low-level formattingA low-level format is a software process that marks the location of disk tracks and sectorsTracks are like several circles around a disk and each track is divided into sections of equal size called sectorsGuide to Operating Systems, 4th ed.
10 Disk Storage Basics Disk tracks and sectors on a platter
Guide to Operating Systems, 4th ed.
11 Block AllocationBlock allocation – divides the disk into logical blocks called clusters, which correlate to sectors, heads, and tracks on the diskKeeps track of where specific files are stored on the diskCylinders – tracks that line up on each platter from top to bottom and are all read at the same timeData regarding block allocation is stored using one of two techniques:File allocation table (FAT)New Technology File System (NTFS) and Unix/Linux file systems – uses various locations on the disk to store a special type of file that is used for directory and file allocation informationGuide to Operating Systems, 4th ed.
12 PartitionsPartitioning – process of blocking a group of tracks and sectors to be used by a particular file system, such as FAT or NTFSAfter partitioning, the disk must be high-level formatted in order for the OS to store filesIt might be necessary for a disk to have more than one file systemWill require a partition for each file systemExample: To allow the installation of Red Hat Enterprise Linux and Windows 7 on the same computerGuide to Operating Systems, 4th ed.
13 PartitionsLogical drives – creating multiple logical volumes on a single disk and assigning drive letters to each volumeWhen a partition is created, information about that partition is stored in a special area of the disk known as the partition table (in MS-DOS, Mac OS, and Windows) and disk label (in UNIX/Linux)Another piece of disk that is reserved is known as the boot block in UNIX/Linux and Mac OS X, or the Master Boot Record (MBR) in MS-DOS and Windows.Guide to Operating Systems, 4th ed.
14 Partitions In Windows, the MBR consists of four elements:
The boot program – examines the partition table to determine which partition to boot fromThe disk signature – stores information about the disk and is used by management software such as the Windows registryThe partition table for the active partitionThe end-of-MBR marker – where the MBR endsNot all operating systems support partitions in the same wayEach operating system uses specific utilities to create partitionsGuide to Operating Systems, 4th ed.
15 FormattingFormatting – the process of placing the file system on the partitionNecessary in order to install an operating systemAfter the OS is installed, a disk management tool can be used to partition and format additional free spaceCan also use the format command from the Command Prompt windowThe format command includes several switches (extra codes)To view a list of these switches, type format /?Guide to Operating Systems, 4th ed.
16 Formatting When a file is stored to disk:
Data is written to clusters on the diskFilename is stored in the folder, along with the number of the first cluster the data is stored inWhen the OS fills the first cluster, data is written to the next free cluster and the FAT entry corresponding with the first cluster points to the number of the second cluster usedWhen the second cluster is full, the OS continues with the next free cluster and the FAT entry for the second cluster points to the number of the third cluster used, and so on…When a file is completely written to the disk, the FAT entry for the final cluster is filled with all 1s (means end of file)This is commonly referred to as the linked-list methodGuide to Operating Systems, 4th ed.
17 Formatting Clusters are a fixed length
When a files does not use all of the space in a cluster, the rest of the cluster is unusableUnusable spots are marked in the FAT as bad clusters (never used for file storage)Each partition stores and extra copy of the FAT table in case the first copy gets damagedThere is only one copy of the root directory on each partition (see figure on the following slide)The FAT tables and root directory are at the beginning of each partition and always at the same locationGuide to Operating Systems, 4th ed.
18 Formatting Typical FAT directory structure
Guide to Operating Systems, 4th ed.
19 FormattingEach FAT directory entry contains filename, file change date and time, file size, and file attributesAttributes can indicate whether a file is set to:Read-onlyArchive (to be backed up the next time a backup is made)SystemHiddenGuide to Operating Systems, 4th ed.
20 Windows File SystemsWindows XP, Vista 7, Server 2003, and Server 2008 support three files systems:Extended FAT16FAT32NTFSThese OSs also support file systems for DVD/CD-ROM drives and USB devices (flash drives)Guide to Operating Systems, 4th ed.
21 FAT16 and Extended FAT16Extended FAT16 evolved from FAT16 used in earlier versions of MS-DOS and Windows (3.x/95/98/Me)In extended FAT16:Maximum size of a volume is 4GBMaximum size of a file is 2GBHas been around for awhile and can be read by non-Windows operating systems like UNIX/LinuxConsidered a stable file systemLong filenames (LFNs) can be usedCan contain up to 255 charactersNot case sensitiveGuide to Operating Systems, 4th ed.
22 FAT32 Support for FAT32 started with Windows 95 Release 2
Designed to accommodate larger capacity disksFAT32:Root folder does not have to be at the beginning of a volumeCan use disk space more efficiently than FAT16 (because it uses smaller cluster sizes)Largest volume that can be formatted is 32 GBMaximum file size is 4 GBOffers fast response on small 1 or 2 GB partitionsGuide to Operating Systems, 4th ed.
23 FAT64 FAT64 is also known as exFAT
Proprietary file system introduced by Microsoft for mobile personal storageGood choice for USB flash devices that may store large files (such as pictures, videos, etc…)Available in Service Pack 1 for Windows Vista, Windows 7, and Windows Server 2008, Mac OS X Snow LeopardSupport is available for Linux from a third partyGuide to Operating Systems, 4th ed.
24 NTFSNTFS – dominant Windows file system for all Windows operating systems starting with Windows 2000Uses a Master File Table (MFT) instead of FAT tablesThe MFT and related files take up about 1 MB of disk spaceWhen a file is created, a record for that file is added to the MFTContains additional attributes such as security settings, ownership, and permissionsGuide to Operating Systems, 4th ed.
25 NTFS The MFT record reflects the sequence of clusters that a file uses
It is possible to have multiple filenames that refer to the same fileA technique known as hard linkingThis feature is also available in UNIX/Linux file systemsWindows Vista, Server 2008, and 7 use NTFS version 6Windows XP and Server 2003 use NTFS version 5Windows NT 4.0 used NTFS 4Guide to Operating Systems, 4th ed.
26 NTFS Basic features of NTFS: Long filenames Built-in security features
Better file compression than FATAbility to use larger disks and files than FATFile activity tracking for better recovery and stability than FATPortable Operating System Interface for Unix (POSIX) supportVolume striping and volume extensionsLess disk fragmentation than FATGuide to Operating Systems, 4th ed.
27 NTFSNTFS is equipped with security features that meet the US government’s C2 security specificationsRefers to high-level, “top-secret” standards for data protection, system auditing, and system accessExamples:System files can be protected so only the server administrator has accessA folder of databases can be protected with read access, but no access to change dataPublic folder can give users in a designated group access to read and update files, but not to delete filesGuide to Operating Systems, 4th ed.
28 NTFS NTFS supports volume striping NTFS has hot fix capabilities
Some files can be compressed by more than 40%, saving disk storage for other storage needsNTFS has the ability to keep a log or journal of file system activity (called journaling)Makes it possible for files to be restored in the event of a power failureNTFS supports volume stripingProcess that equally divides the contents of each file across two or more volumes to extend disk life, enable fault tolerance, and balance disk load for better performanceNTFS has hot fix capabilitiesIf a bad disk area is detected, automatically copies the information to another disk area that is not damagedGuide to Operating Systems, 4th ed.
29 NTFS In addition to NTFS 4 features, NTFS 5 adds several new features:
Ability to encrypt filesNo system reboot required after creating an extended volumeAbility to reduce drive designationsIndexing for fast accessAbility to retain shortcuts and other file information when files and folders are placed on other volumesAbility to establish disk quotas (to control how much disk space users can occupy)Guide to Operating Systems, 4th ed.
30 NTFS NTFS 6 (latest version) adds several new features:
Transactional NTFS – used to perform operations in transactions (all at once or not all)Partition resizing – allows administrator to expand or shrink partitionsSelf-healing – the chkdsk utility runs in the background to correct hard disk problems (instead of having to take the volume down to run it)Guide to Operating Systems, 4th ed.
31 NTFSThe chkdsk utility can detect and fix an extensive set of file system problems in FAT and NTFS systemThis utility is available in all versions of Windows starting with Windows 2000The most common problems found are files with 0 sizes, caused when a file is not properly closed or chains of clusters that have no directory entriesWindows 2000 and later versions have a built-in disk defragmenting toolRearranges data on the disk in a continuous fashion, ridding the disk of scattered open clustersGuide to Operating Systems, 4th ed.
32 NTFS FAT16, FAT32, FAT64, and NTFS compared
Guide to Operating Systems, 4th ed.
33 CDFS and UDFWindows versions after Windows 2000 recognize some additional file systems used by peripheral storage technologiesCD-ROM File System (CDFS) – supported so that OSs can read and write files to DVD/CD-ROM drivesUniversal Disk Format (UDF) – also used on DVD/CD-ROMs, which are used for huge file storage to accommodate movies and gamesGuide to Operating Systems, 4th ed.
34 The UNIX File SystemThere are many different file systems that can be used with UNIXSome file systems are more “native” to specific UNIX operating systems than othersMost versions of UNIX and Linux support the UNIX file system (ufs), which is the original native UNIX file systemufs is a hierarchical file system that is expandable, supports large storage, provides excellent security, and is reliableMany qualities of NTFS are modeled after ufs (journaling and hot fixes)Guide to Operating Systems, 4th ed.
35 The UNIX File SystemIn Linux, the native file system is called the extended file system (ext or ext fs)ext is modeled after ufs and enables the use of the full range of built-in Linux commands, file manipulation, and securityThe first ext version had bugsext2 – reliable file system that handles large disk storageext3 – added journaling capabilitiesext4 – supports file sizes up to 16 TBGuide to Operating Systems, 4th ed.
36 The UNIX File System Both ufs and ext use the same structure
Built on the concept of information nodes (or inodes)Each file has an inode and is identified by an inode numberAn inode contains general information about that file such as:User and group ownership, permissions, size and type of file, date the file was created, and the date the file was last modified and readEach disk is divided into logical blocksThe superblock contains information about the layout of blocks, sectors, and cylinder groups on the file systemThe inode for a file contains a pointer (number) that tells the OS where to find a file on the hard disk (based on logical blocks)Inode 0 contains the root of the folder structure and is the jumping off point for all other inodesGuide to Operating Systems, 4th ed.
37 The UNIX File System A UNIX/Linux system can have many file systems
Mounts file systems as a sub file system of the root file systemAll file systems are referred to by a pathThe path starts out with / (/ indicates the main root directory of the file system)See Figure 4-14 on the next slide for examplesDirectories in the file system contain a series of filenamesUNIX/Linux allows the use of long filenames, which may include any character that can be represented by ASCIIGuide to Operating Systems, 4th ed.
38 The UNIX File System UNIX/Linux file system path entries
Guide to Operating Systems, 4th ed.
39 The UNIX File SystemDisks are referenced by a special inode called a deviceThere are two types of devices:Raw device – has no logical division in blocksBlock device – does have logical division in blocksDevices are normally kept in the /dev or /devices directorySymbolic link – used to link a directory entry to a file that is on a different partitionMerely a pointer to a fileGuide to Operating Systems, 4th ed.
40 The UNIX File SystemYou must first partition a disk to use the UNIX/Linux file systemThe command to partition the disk differs slightlyMost UNIX systems use either fdisk or formatTyping man fdisk or man format at the command prompt gives you an overview of available commandsGuide to Operating Systems, 4th ed.
41 The UNIX File SystemOnce a partition is made, a file system can be createdYou must know the device name of the partition on which you wish to create a file systemType newfs, followed by the name of the deviceThe newfs command is not available in all versions of LinuxUse the mkfs command insteadGuide to Operating Systems, 4th ed.
42 The UNIX File SystemWhen a file is saved to disk, the system first stores part of the data to memory until it has time to write to diskIf computer is shut down prior to data being written to disk, you can end up with a damaged file systemUNIX/Linux systems should always be shut down using proper shutdown commandsYou can manually force a write of all data in memory by using the sync commandAnother utility is known as fsckVerifies the integrity of the superblock, the inodes, all cluster groups, and all directory entriesGuide to Operating Systems, 4th ed.
43 The UNIX File System UNIX/Linux file system commands
Guide to Operating Systems, 4th ed.
44 The Macintosh File System
The original Macintosh Filing System (MFS) of 1984 was limitedKept track of 128 documents, applications or foldersReasonable limit when the only storage device was a 400 KB floppy disk driveIn 1986, Apple created Hierarchical Filing System (HFS)Divided a volume (disk partition) into allocation blocks – similar to clusters on PCsIn 1998, Apple released Mac OS 8.1 with a new file system called Hierarchical Filing System Extended Format (HFS+)Guide to Operating Systems, 4th ed.
45 The Macintosh File System
In Mac OS X version 3.0, Mac OS Extended (HFS+) includes new features:A case-sensitive format to make the file system more compatible with other UNIX/Linux systemsJournalingAbility to store up to 16 TB of dataThe first two sectors of a Mac-formatted disk are:Boot sectors, or boot blocksVolume information block – contains catalog b-treeCatalog b-tree is a list of all files on the volume and keeps track of a file’s name, location in the folder structure, and its physical locationGuide to Operating Systems, 4th ed.
46 The Macintosh File System
Macintoshes can read and write to disks from other operating systemsMac OS has always supported what might be called medium filenames (up to 31 characters)Any character may be used in a filename except the colon (:)Reason for this: Macintosh paths are written as colon-separated entities such as:Hard Drive:System Folder:Preferences:Finder PrefsMac uses type codes and creator codes instead of filename extensions as in WindowsFiles created with Apple’s SimpleText editor have a type code of APPL and a creator code of ttxtGuide to Operating Systems, 4th ed.
47 The Macintosh File System
Macintosh files can contain two parts, or forks:Data fork – contains frequently changing information (such as word processing data)Resource fork – contains information that is fixed (such as a program’s icons, menu resources, and splash screens)Because Mac files have type and creator codes and two forks can create problems when storing files on non-Macintosh serversMacBinary – format which joins the two forks into one, and safely stores the type and creator codes and finder flagsGuide to Operating Systems, 4th ed.
0 thoughts to “Guide to operating systems 4th edition pdf download romsho”