StudentShare
Contact Us
Sign In / Sign Up for FREE
Search
Go to advanced search...
Free

Using the Disk Head Simulator - Report Example

Cite this document
Summary
This report "Using the Disk Head Simulator" discusses secondary storage as a very significant component of a computer’s operating environment. It provides an important large storage space that can permanently hold systems software and any other desired user data…
Download full paper File format: .doc, available for editing
GRAB THE BEST PAPER97% of users find it useful
Using the Disk Head Simulator
Read Text Preview

Extract of sample "Using the Disk Head Simulator"

Using the Disk Head Simulator Introduction Secondary storage is a very significant component of a computer’s operating environment. It provides an important large storage space that can permanently hold systems software and any other desired user data. Secondary storage can also be utilized as a backup to ensure that the computer system is reliable and that data carried is safe. In addition, secondary storage also known as the Disk system supports the operations of the main memory. Therefore, we can say that the optimal performance of the disk is crucial since it affects the overall operation of the system (Silberschatz, Galvin and Gagne). To be able to read or write a sector of the disk, the disk arm needs to first and foremost search for targeted track. This, if not optimized, the time required to complete the search also referred to as the seek time, will be far much higher than anticipated. This time also depends on the distance between the position of the current read/write and the location of track that is required. On touching the track, the rotation of the occurs so as to ensure that the desired sector is under read/write. This time is referred to as the rotation time and is usually known in advance. In order to ensure optimal performance of the system through reduction of the seek, transfer and rotation time, a disk arm scheduling technique is required. This scheduling techniques is able to schedule or organize different sets of requests in such a way that an overall minimum seek time is achieved. This project thus utilizes a Disk arm Scheduling Simulator. The Disk Head Simulator is an application implemented in Java and is utilized in the exploration of several aspects of disk head scheduling. Several standard scheduling algorithms including Shortest Seek Time First (SSTF), First-Come/First-Served, Look, Scan, C-look, and C-Scan are supported by this application. Blocks that the algorithms are to seek are either generated on the go using distributions or are set up as a list in a file. In most cases the blocks can either all arrives at a later time or before the simulation begins (Using the Disk Head Simulator). When carrying out this simulation, the seek time can be assumed as any linear function of the cylinders available. This Disk Head Simulator offers support to both a zoned block layout where the physical disks are subdivided into sections and a uniform layout of blocks, i.e. each cylinder having a fixed number of blocks. The Disk Head Simulator assumes that the scheduling is entirely being done by the OS (operating system). Normally, the simulator assumes that the OS has knowledge of how the disk is layered or the disk is able to use any layout. For instance, the OS can utilize the logical block addressing whereby it assumes that each cylinder is associated with a particular block and the disk has a zoned physical layout. Through the use of the Disk Head Simulator, we are able to explore this mismatch. Numerical and graphical analysis of these algorithms may be preferred for scheduling analysis. Project Description This Disk Head Simulator requires a computer to be ready with a JRE version 1.1 or greater. However, Java 1.6 or later is recommended. In order to run this simulator without any problems, the following files needs to be installed correctly: Jeli.jar myexp.exp DiskHead.jar myrun.run rundisk.bat diskheadconfig This project was carried out in a Windows environment with a JRE 1.6 installed. This project or experiment focused and simulated the Shortest Seek Time First (SSTF) Algorithm. Definition The Shortest Seek Time First disk head scheduling algorithm is similar to the Shortest Job First CPU scheduling algorithm. It aims at serving all request that are close to the current position of the disk head before attending to those requests that are further away. It selects those requests that have the minimum seek time from the disk’s head current position because with increase in the number of traversed cylinders by the head, seek time increase. Due to its policy of choosing the request with the shortest seek time, this algorithm may cause starvation for other requests. Run Implementation For this implementation run, I first ensured that all the required files, i.e. Jeli.jar, myexp.exp, DiskHead.jar, myrun.run rundisk.bat, diskheadconfig were installed correctly in one folder. Then, I started the simulator by executing the rundisk.bat in the command prompt. The resultant was a startup screen as the one shown below. Fig. 1: The Start screen for the Disk Head Simulation Java application Once the simulator was up and running, I then run the experiment by clicking on the button labeled “Run Experiment.” Then, I opened the experiment log by clicking on the button labeled “open log.” This would allow me to save/log any data, graphs or tables that I obtained from the experiment run. In order to get table data and graphs related to the SSTF I pressed the buttons “Show Run Data Graph,” “Show Run Table Data,” and “Show Table Data.” Since my experimental run had several algorithms including SSTF, FCFS, and C-LOOK, I was provided with a dropdown list from which I had to choose the SSTF algorithm. Table Data, Run Table and Run Data graph were each displayed in a separate window. To store this data, I logged them in the experiment log where they were saved. The experiment log containing graphs, data tables and the myrun.run and myexp.exp files is shown below. Disk Head Simulator Log for New User generated Sat Mar 24 22:40:32 EDT 2012 Disk Head Simulation by S. Robbins version 1.02L288 Supported by NSF DUE-0088769 Last modified January 2, 2007 using Jeli L288 last modified March 1, 2007 See http://vip.cs.utsa.edu/nsf for simulator information. Java version 1.6.0_17 OS Windows 7 version 6.1 20016484055 Configuration file diskheadconfig follows: user New User quiet exp myexp run myrun Number of runs is 1 Run file myrun.run follows: name myrun comment This is team7 start 5 movement linear 0.8 0.12 layout uniform 4 head clook interArrival constant 0 nextBlock uniform 40 50 firstArrival 0.0 blockAbsolute numBlocks 12 Number of experiments is 1 Experiment file myexp.exp follows: name myexp comment Three runs with different algorithms run myrun key "FCFS" head FCFS run myrun key "SSTF" head SSTF run myrun key "C-LOOK" head CLOOK Starting experiment myexp at Sat Mar 24 22:40:47 EDT 2012 Starting run with key FCFS and seed 12345 Run took .031 seconds Starting run with key SSTF and seed 12345 Run took .020 seconds Starting run with key C-LOOK and seed 12345 Run took .022 seconds Experiment took .110 seconds Sat Mar 24 22:41:01 EDT 2012 Seek Movement Seek Time Max Run Key Layout Algorithm Count Algorithm Total Idle Queue myrun FCFS Uniform 4 FCFS 12 Linear .80 .12 10.52 0.00 11 myrun SSTF Uniform 4 SSTF 12 Linear .80 .12 3.72 0.00 11 myrun C-LOOK Uniform 4 C-LOOK 12 Linear .80 .12 3.72 0.00 11 Seek Movement Seek Time Seek Request Turnaround Run Key Mean Min Max SD Mean Min Max SD Mean Min Max SD myrun FCFS 6.83 2.00 41.00 10.91 .88 0.00 2.00 .51 6.66 2.00 10.52 2.87 myrun SSTF 4.33 0.00 38.00 10.65 .31 0.00 1.88 .61 2.72 1.88 3.72 .73 myrun C-LOOK 3.67 0.00 36.00 10.21 .31 0.00 1.88 .61 2.72 1.88 3.72 .73 Sat Mar 24 22:42:01 EDT 2012 SSTF This SSTF graph illustrates the completed run experiment under the SSTF algorithm. It shows the positions of the disk head as the experiment progressed depending on the position of each request with respect to the initial position of the disk head. Sat Mar 24 22:42:22 EDT 2012 SSTF This image is a line that represents the initial position of the disk head for the SSTF algorithm experimental run. This is obtained when the demo button in the graph window is pressed. The demo is aimed at illustration exactly how the complete graph was arrived at by showing how the head moved to attend to the various requests. Sat Mar 24 22:42:48 EDT 2012 SSTF As explained above, the red line illustrates the initial or the current position of the disk head. In other words, it represents the position of the request currently being written to/read by the disk head. The green line represents the next and the nearest request that the head would be attending to. Sat Mar 24 22:42:53 EDT 2012 SSTF The horizontal line demonstrates the movement of the disk head. If the disk head changes direction so as to attend to the next nearest request, that movement is represented by a vertical line as illustrate in this figure. If the next request or the next seek is in the same direction, the horizontal line continues but is marked by a tick to indicate the position of that seek or request. Sat Mar 24 22:43:02 EDT 2012 SSTF The horizontal line demonstrates the movement of the disk head. If the disk head changes direction so as to attend to the next nearest request, that movement is represented by a vertical line as illustrate in this figure. If the next request or the next seek is in the same direction, the horizontal line continues but is marked by a tick to indicate the position of that seek or request. Sat Mar 24 22:43:26 EDT 2012 SSTF The horizontal line demonstrates the movement of the disk head. If the disk head changes direction so as to attend to the next nearest request, that movement is represented by a vertical line as illustrate in this figure. If the next request or the next seek is in the same direction, the horizontal line continues but is marked by a tick to indicate the position of that seek or request. Sat Mar 24 22:44:12 EDT 2012 SSTF The horizontal line demonstrates the movement of the disk head. If the disk head changes direction so as to attend to the next nearest request, that movement is represented by a vertical line as illustrate in this figure. If the next request or the next seek is in the same direction, the horizontal line continues but is marked by a tick to indicate the position of that seek or request. Sat Mar 24 22:44:21 EDT 2012 SSTF The horizontal line demonstrates the movement of the disk head. If the disk head changes direction so as to attend to the next nearest request, that movement is represented by a vertical line as illustrate in this figure. If the next request or the next seek is in the same direction, the horizontal line continues but is marked by a tick to indicate the position of that seek or request. Sat Mar 24 22:44:25 EDT 2012 SSTF The horizontal line demonstrates the movement of the disk head. If the disk head changes direction so as to attend to the next nearest request, that movement is represented by a vertical line as illustrate in this figure. If the next request or the next seek is in the same direction, the horizontal line continues but is marked by a tick to indicate the position of that seek or request. myrun SSTF Block Time From To Request Start End Seek Turnaround 5 43 0.00 0.00 1.88 1.88 1.88 43 41 0.00 1.88 1.88 0.00 1.88 41 41 0.00 1.88 1.88 0.00 1.88 41 43 0.00 1.88 1.88 0.00 1.88 43 46 0.00 1.88 2.80 .92 2.80 46 46 0.00 2.80 2.80 0.00 2.80 46 45 0.00 2.80 2.80 0.00 2.80 45 47 0.00 2.80 2.80 0.00 2.80 47 46 0.00 2.80 2.80 0.00 2.80 46 48 0.00 2.80 3.72 .92 3.72 48 49 0.00 3.72 3.72 0.00 3.72 49 49 0.00 3.72 3.72 0.00 3.72 4.33 Mean .31 2.72 0.00 Minimum 0.00 1.88 38.00 Maximum 1.88 3.72 10.65 Standard Deviation .61 .73 This table contains data relating to the SSTF run and shows the time that a request arrived, which block is in, the time the seek is started and ended, and the seek time. The above graphs are based on this data. myrun SSTF Block Time From To Request Start End Seek Turnaround 5 43 0.00 0.00 1.88 1.88 1.88 43 41 0.00 1.88 1.88 0.00 1.88 41 41 0.00 1.88 1.88 0.00 1.88 41 43 0.00 1.88 1.88 0.00 1.88 43 46 0.00 1.88 2.80 .92 2.80 46 46 0.00 2.80 2.80 0.00 2.80 46 45 0.00 2.80 2.80 0.00 2.80 45 47 0.00 2.80 2.80 0.00 2.80 47 46 0.00 2.80 2.80 0.00 2.80 46 48 0.00 2.80 3.72 .92 3.72 48 49 0.00 3.72 3.72 0.00 3.72 49 49 0.00 3.72 3.72 0.00 3.72 4.33 Mean .31 2.72 0.00 Minimum 0.00 1.88 38.00 Maximum 1.88 3.72 10.65 Standard Deviation .61 .73 Disk Head Info Disk Head Simulation by S. Robbins version 1.02L288 Supported by NSF DUE-0088769 Last modified January 2, 2007 Java version 1.6.0_17 OS Windows 7 version 6.1 Sat, Mar 24, 2012 at 10:40:47 EDT: Starting run with key FCFS and seed 12345 Sat, Mar 24, 2012 at 10:40:47 EDT: Run is done in .031 seconds. Sat, Mar 24, 2012 at 10:40:47 EDT: Starting run with key SSTF and seed 12345 Sat, Mar 24, 2012 at 10:40:48 EDT: Run is done in .020 seconds. Sat, Mar 24, 2012 at 10:40:48 EDT: Starting run with key C-LOOK and seed 12345 Sat, Mar 24, 2012 at 10:40:48 EDT: Run is done in .022 seconds. Sat Mar 24 22:45:17 EDT 2012 Seek Movement Seek Time Max Run Key Layout Algorithm Count Algorithm Total Idle Queue myrun FCFS Uniform 4 FCFS 12 Linear .80 .12 10.52 0.00 11 myrun SSTF Uniform 4 SSTF 12 Linear .80 .12 3.72 0.00 11 myrun C-LOOK Uniform 4 C-LOOK 12 Linear .80 .12 3.72 0.00 11 Seek Movement Seek Time Seek Request Turnaround Run Key Mean Min Max SD Mean Min Max SD Mean Min Max SD myrun FCFS 6.83 2.00 41.00 10.91 .88 0.00 2.00 .51 6.66 2.00 10.52 2.87 myrun SSTF 4.33 0.00 38.00 10.65 .31 0.00 1.88 .61 2.72 1.88 3.72 .73 myrun C-LOOK 3.67 0.00 36.00 10.21 .31 0.00 1.88 .61 2.72 1.88 3.72 .73 These tables contain data for all the algorithms that were run in this experiment. It gives a clear comparison of the different algorithms that were run including FCFS, SSTF, and the C-LOOK. Conclusion The SSTF scheduling algorithm results in almost one-third more than the distance that FCFS scheduling algorithm would have taken if it was used for this queue. This implies that, compared to the FCFS algorithm, it offers a substantially improved performance. However, SSTF algorithm is not optimal and may at times cause starvation of some request which might have arrived earlier but are far away from the others and the current position of the disk head. Therefore, it can be concluded that the SSTF scheduling algorithm when compared to the FCFS algorithm reduces the total cylinder movement of the head but is not optimal just as the SJF algorithm. Works Cited Silberschatz, Abraham, Peter B. Galvin and Greg Gagne. Operating System Concepts. 7. New York: J. Wiley & Sons, 2005. Print. Tanenbaum, Andrew S. Modern operating systems. 3. New Jersey: Pearson Prentice Hall, 2008. Print. Using the Disk Head Simulator. 2 March 2004. Web. 26 March 2012 . Read More
Cite this document
  • APA
  • MLA
  • CHICAGO
(Using the Disk Head Simulator Report Example | Topics and Well Written Essays - 2250 words, n.d.)
Using the Disk Head Simulator Report Example | Topics and Well Written Essays - 2250 words. https://studentshare.org/logic-programming/1770096-using-the-disk-head-simulator
(Using the Disk Head Simulator Report Example | Topics and Well Written Essays - 2250 Words)
Using the Disk Head Simulator Report Example | Topics and Well Written Essays - 2250 Words. https://studentshare.org/logic-programming/1770096-using-the-disk-head-simulator.
“Using the Disk Head Simulator Report Example | Topics and Well Written Essays - 2250 Words”. https://studentshare.org/logic-programming/1770096-using-the-disk-head-simulator.
  • Cited: 0 times

CHECK THESE SAMPLES OF Using the Disk Head Simulator

PDA Simulation for Marketing

Jabido Academia Research May 8, 2011 Analysis On the PDA simulator I had a final score of 1,185,800,553.... I have made numerous attempts using a simulator to prove that my strategies worked better.... academia research Time Warp PDA Simulation for Marketing Maribel P....
5 Pages (1250 words) Essay

Risk Writing Option: Live Poetry

I was so amazed at the talents of artists who delivered poetry using precise diction, grammar, pronunciation, rhythm and expression that assisted the audience in being emotionally enthralled by their performances.... Risk Writing Option: Live Poetry By: ENGIIIFl!... Thesis Statement: < I consider delivering live poetry as a performance involving personal risk that definitely brought me out of my comfort zone....
3 Pages (750 words) Essay

Choose from description below

The authors shed light on the major effects on driving using a phone at the same time judging from the simulator works and field research.... With driving taking the toll of using one hand, while the other is busy texting or receiving a call, Lee argues that a lot of lives have been lost as a result of the same (7728)....
3 Pages (750 words) Research Paper

Registers and Memory Devices

MOS RAM: CMOS RAM is a term for the small amount of memory used by your computer and some other devices to remember things like hard disk settings.... Read-Only-Memory (ROM) and Random-Access-Memory (RAM) are a form of computer data storage.... ROM, also called a firmware, is an 'integrated circuit programmed with specific data when it is manufactured' (Tyson, 2000)....
3 Pages (750 words) Essay

Simulation, Achieving Project Goals

In order to properly manage these activities companies many times formulated project teams.... Project management is an organizational management system that… s employees to specific project teams when special projects are contracted and then reassigns them back to the organization once the project is completed (Answers, 2009)....
4 Pages (1000 words) Essay

Week 2 response papers

Since the atmosphere is one, tests should be done using simulators with various factors conditioned to meet its (the atmosphere's) specifications.... It is true that the environment or different ecosystems do not require human intervention to function naturally and to reinvent in case they (the ecosystems) are negatively affected....
2 Pages (500 words) Essay

University of Miami

Ultimately, whereas traditional aircraft could rely upon the knowledge, intuition, and visual references that the pilot himself can draw… Similarly, as one might expect, the gap between needs and the exhibition of technological prowess within the UAV is high due to the fact that the As a function of this, UAVs operating in various places throughout the world, namely Iraq and Afghanistan, began to suffer a high attrition rate due to the icing of the wings that invariably occurs at high attitudes....
8 Pages (2000 words) Essay

Field Instrument Calibration, Test and Troubleshooting

It is made using the ZERO and SPAN of the potentiometers.... Calculate the reading expected using the formula provided.... You may use either the RSP transmitterto perform calibration of the display or a 4-20 ma signal simulator.... Attach the POSITIVE lead of the simulator to the RED lead of the LCD display, and theNEGATIVE lead of the simulator to the BLACK lead of the LCD display.... The simulator should be set to POWERED output mode so that loop power is supplied....
7 Pages (1750 words) Term Paper
sponsored ads
We use cookies to create the best experience for you. Keep on browsing if you are OK with that, or find out how to manage cookies.
Contact Us