The document describes a case study analyzing the results of running the SKIPPY disk analysis algorithm on a mock disk called Disk Alpha. It then asks the reader to draw an approximation of what the results would look like for a different disk, Disk Beta, with different parameters such as minimal transfer time and rotational latency. Finally, it provides theoretical background on how the SKIPPY algorithm works to extract disk parameters like head switch time by linearly increasing the distance between write accesses.
The document describes a case study analyzing the results of running the SKIPPY disk analysis algorithm on a mock disk called Disk Alpha. It then asks the reader to draw an approximation of what the results would look like for a different disk, Disk Beta, with different parameters such as minimal transfer time and rotational latency. Finally, it provides theoretical background on how the SKIPPY algorithm works to extract disk parameters like head switch time by linearly increasing the distance between write accesses.
The document describes a case study analyzing the results of running the SKIPPY disk analysis algorithm on a mock disk called Disk Alpha. It then asks the reader to draw an approximation of what the results would look like for a different disk, Disk Beta, with different parameters such as minimal transfer time and rotational latency. Finally, it provides theoretical background on how the SKIPPY algorithm works to extract disk parameters like head switch time by linearly increasing the distance between write accesses.
Case Studies with Exercises by Andrea C. Arpaci-Dusseau and Remzi H. Arpaci-Dusseau
13.1 The results of running Skippy are shown for a mock disk (Disk Alpha) in Figure 6.25
a. What is the minimal transfer time?
b. What is the rotational latency? c. What is the head switch time? d. What is the cylinder switch time? e. What is the number of disk heads? 13.2 Draw an approximation of the graph that would result from running Skippy on Disk Beta, a disk with the following parameters: • Minimal transfer time: 2.0 ms • Rotational latency: 6.0 ms • Head switch time: 1.0 ms • Cylinder switch time: 1.5 ms • Number of disk heads: 4 • Sectors per track: 100 - Theory Figure 1: SKIPPY Algorithm. The basic algorithm skips through the disk, increasing the distance of the seek by one sector before every write, and outputs the distance and time for each write. The raw device interface must be used in order to avoid file system optimizations. SINGLE SECTOR is the size of a single sector, in this case, 512 bytes. The SEEK CUR argument to lseek moves the file pointer an amount relative to the current pointer.
fd = open("raw disk device");
for (i = 0; i < measurements; i++) { // time the following sequence, and output <i, time> lseek(fd, i * SINGLE_SECTOR, SEEK_CUR); write(fd, buffer, SINGLE_SECTOR); } close(fd); Рис 1. Intuition and Analytical Foundation Traditionally, extracting parameters like the head switch time from a disk drive has been difficult since each request incurs an unpredictable rotational latency. The intuition behind the linearly increasing stride method is as follows. Between any two write accesses, the drive rotates some distance forward. Even though different requests will incur different latencies, the time between successive requests reaching the disk is roughly the same. Since the step size between requests is linearly increasing, it will eventually match the distance that the disk rotates between successive requests. This point is clearly observable since all requests prior to it will incur an extra rotation and all requests afterward will not. Basically, since the access pattern is designed to take advantage of the rotational mechanism, it is possible to separate the rotational latency of a request from all other contributing latencies. As a result, other disk characteristics, including head and cylinder switch times, are clearly observable. To better describe how SKIPPY works, we use a simple analytical model. The model uses the following terms: