Big Alice plays the disk Crockett - the basic elevator algorithm
- When writing to a hard disk - size and location matters.
- I/O time depends on seek time plus data transfer time.
- The disk always rotates - so we need to schedule I/Os as close to the
current read-head location as possible to reduce seek time.
- The problem - the disk does not expose its physical geometry.
- So the solution: ordering requests based on sector address
- and making sure not to make the disk head "jump":
- First move the elevator up: perform all I/Os from low address to high
address.
- If a request arrives, whose address is lower than the current I/O - it
will wait for the elevator to come back down.
- When there are no I/Os in the elevator's current direction - switch
direction.
Originally written by
guy keren