2File SystemsA file system defines the structure and the rules used to read, write, and maintain information stored on a disk.Which system used is determined by;HardwareSoftwareSecurity needsNeed for a dual-booting system
3FAT???file allocation table – where the OS records how the disk space is used
4File SystemsFAT 16 – oldest, created for DOS, supported by most OSs’, cannot be installed on partitions larger than 2 GB, or on hard drives larger than 4GB.FAT 32 – supports disks from 512 to 2TB, compatible with Windows 98 and upNTFS – (new technology file system) – better file security (Encrypting File System), disk compression, logging features, reliability and stability. NTFS volumes can not be accessed by DOS, or Windows 95 or Windows 98.
5File SystemsThe operating system keeps track of data (documents, pictures, etc.) by placing it into a file.To store and retrieve files:Disk divided into tracksTracks are divided into sectorsSectors grouped into clustersNumber of sectors in a cluster is determined bySize of the hard driveFile allocation system – FAT, FAT32, NTFS, e
6When you format a disk the operating systems creates concentric recording bands, called tracks, around the circumference of the disk. Then, the formatting program (in our case Windows XP) subdivides each track into equal parts, called sectors. Although not all of them are shown in the following diagram, there are 80 concentric tracks on a 3 ½ inch high density diskette and each track is divided into 18 sectors. Each sector in turn contains 512 bytes.So let’s see tracks X 18 sectors X 2 sides X 512 bytes = 1,474,560 bytes = 1.4 MB
8A hard disk has extremely smooth metal or glass plates called “platters” (vs. the floppy mylar disk of a floppy disk).Each platter is divided into tracks and sectors by the format operation, like a floppy disk, however the number of tracks and sectors is different. The number of tracks on a hard disk depends on the disk size and the manufacturer.
9Clusters?A cluster, also known as an allocation unit, consists of one or more sectors of storage space, and represents the minimum amount of space that an operating system allocates when saving the contents of a file to a disk.The number of sectors per cluster is dependent onType of disk (floppy disk, hard disk)Version of operating systemsSize of diskEvery sector contains 512 bytes. (NTFS does allow you to change this number.)The number of clusters per disk is determined by the filing system (FAT 16, FAT 32 or NTFS).
10DRIVE SIZE Cluster Size FAT 16Cluster SizeFAT 32NTFS260 to 511 MB8 KB (16 sectors)Not Supported512 bytes (1 sector)512 to 1023 MB16 KB (32 sectors)4 KB (8 sectors)1KB (2 sectors)1024 MB to 2 GB32 KB (64 sectors)2 KB (4 sectors)2 to 4 GB64 KB (128 sectors)4 to 8 GB8 to 16 GB16 to 32 GB32 KB ( 64 sectors)>32 GB (up to 2 TB)
11Example - File size = 2KBHard drive = 2GBFAT 16 – the file will use 1 cluster which is 64 sectors, so64 X 512 bytes per sector = 32KB – 2KB = 30KB slack spaceFAT 32 – the file will use 1 clusters which is 8 sectors, so8 X 512 bytes per sector = 4KB – 2KB = 2KB slack spaceNTFS – the file will use 1 cluster which is 4 sectors, so4 X 512 bytes per sector = 2KB – 2KB = 0 slack space
12So, what does this all mean to us, as Windows XP users? The bigger your disk – the bigger your clusters (because there is a maximum number of clusters per disk).One way to help alleviate the problem of slack space is to partition the hard drive into smaller “drives”. Reducing the drive size will reduce the cluster size.
13So what can cause problems with a Disk? Physical hard drive problems:Wear and tear on hard disk - Minimize with Power Management and/or HibernationHead crash - Minimize by placing system where it will not get knocked around.Software-related problems:Viruses -Minimize by using virus protection softwareSome error causing conditions to data that may be repairable:Power surgesPower outagesLocked system
14Cleaning Up Your DiskComputer performance depends a great deal on the hard drive.Need disk space for:New filesTemporary filesDocuments waiting to be printedCache filesCache – storage area for often used information that can be accessed quicklyRecycle
15Cleaning Up Your Disk Will remove the following; Disk cleanup is a utility that helps maintain the hard disk.Intended for hard drives.Will remove the following;Internet cache filesDownloaded program filesOffline web pagesOffline lines, & temporary offline filesTemporary filesFiles in the recycle binWindows components that you no longer useInstalled programs that you no longer useCatalog files for the Content Indexer
16Check DiskThe Check Disk utility is a disk analysis and repair utility that examines disks for errors and, where possible, repairs errors.Checks the logical structureChecks the physical integrity of the disk’s surface, if it finds a bad sector it will attempt to move the data to another location.Take care of Lost Clusters
17What are lost clusters? Lost Clusters: Reasons for Lost Clusters Have no directory entry in directory tableDo not belong to any fileTake up disk space -Unavailable for new dataCannot be retrieved/deletedReasons for Lost ClustersNot exiting program properlyPower surge/failure
19Check Disk can fix lost clusters Can fix lost clusters automatically orSave them to disk as filesSide note:You can check if you have lost clusters by clicking on a file and comparing the file size in explorer window to status bar files size.
20Check Disk continuedCAN check/repair local hard drives, floppy disks, and removable drivesCANNOT find/fix errors on CD-ROMs or network drives
21Check Disk, continued Should be used on a regular basis The first time you use it you should back up your disk before running check disk.Close all open programs when using this program, including screen saverIf disk is formatted as NTFS, Windows XP Professional will automatically (without running Check Disk):Log all file transactionsReplace bad clustersStore copies of key information for all files on NTFS volume
22Contiguous and Noncontiguous Files Windows XP Professional keeps track of data by placing it into a file.To store and retrieve files:Disk divided into sectorsSectors grouped into clustersNumber of sectors in a cluster is determined bySize of the hard driveFile allocation system – FAT, FAT32, NTFS, etc.
23Contiguous and Noncontiguous Files When a file is deleted:Only entries in FAT deletedSpace file occupied becomes available
24Contiguous and Noncontiguous Files Files are:Contiguous – written to adjacent clusters on a diskNoncontiguous (fragmented) – written to a disk in nonadjacent clusters.So a Fragmented Disk has noncontiguous files. It takes longer to read a Fragmented Disk because the head must move around so much going to the various locations of the file clusters.
28DefragmentationRearranges the files on a disk so that all parts of each files are store in consecutive clusters.It also records the clusters for one file right after the clusters for another file, and in the process, removes free space between files that would result in more fragmentation.At the end of defragmentation all the unused space is near the inner edge of the disk.
29Defragmentation, continued Prior to running Disk Defragmenter:Run Check Disk and Disk CleanupClose All open programsAllow ample time, can take hours – depends on how fragmented your disk is.Back up disk