150 likes | 312 Views
2/24: Disk Optimization. Roll Call Lecture: defragmentation, disk compression, file compression, drive arrays. Review: what we know so far. Formatting disks: why? Writing files to a disk Reading files from a disk. Defragmention: what is it?.
E N D
2/24: Disk Optimization • Roll Call • Lecture: defragmentation, disk compression, file compression, drive arrays
Review: what we know so far. • Formatting disks: why? • Writing files to a disk • Reading files from a disk
Defragmention: what is it? • Rejoining parts of files that were written in different places on the disk drive.
2. Defragmention: why do we need it? • In the beginning, the hard drive is empty and formatted. • Files are written, one by one. • Files are deleted, one by one.
3. Defrag: Hooh! What is it good for? • New files are saved in places that the old files leave vacant. • The read/write heads have to look all over for the data.
4. Time keeps on slippin’, slippin’, ... • The access time is reduced as the heads move more to get the data. • Access time is defined as “how long it takes to retrieve data.”
5. Defrag is a compulsive organizer. • The defrag moves some clusters of data to empty places so it can put related data in its place. • It continues until everything is sorted.
6. Defrag speeds it up. • The defrag allows the disk drive to be accessed more efficiently, thus speeding up the access time.
Part 2: Disk compression 1 cluster • Disk compression allows you to pack more onto your hard drive. • Disk compression is NOT file compression. Regular disk file system Compressed disk file system
SLACK #1 #2 #3 #4 #5 #1 #2 #3 #4 #5 1: How does disk compression work? 1 cluster • Software creates a file that contains all the files that are on your disk. • This file is called a CVF (compressed volume file). Regular disk file system Compressed disk file system
SLACK 2. Virtual drives 1 cluster • The CVF is seen by the OS as a separate drive, with its own letter & designation. • A virtual drive. #1 #2 #3 #4 #5 Regular disk file system #1 #2 #3 #4 #5 Compressed disk file system
Part 3: File compression • Repeated parts of the text are saved with markers put in their places. she sells seashells down by the seashore. she sells seashells down by the seashore. she_sells_seashells down by the_seashore.
File compression w/ text. she sells seashells down by the seashore. 41 characters. # sells sea#lls down by theseashore. she 40 characters. #@lls@a#llsdown by the@ashore. she_se 37 characters.
File compression w/ graphics. • Graphic files use various methods of compression. • One is called lossycompression, in which gradations in color are lost. • It is permanent.