D
Dan Irwin
I know this is a kind of stubid question, but what does the buffer on hard drive do?
drive do?Dan Irwin said:I know this is a kind of stubid question, but what does the buffer on hard
Ruth said:it buffers
ok...enough with the schmarty pants
Buffer is a place to hold data that comes from the drive, that may available
before the CPU is ready for it. If that happens, then when CPU is ready, if
the data isn't available, it has to call the drive up and say "hey you
remember that data i asked for a few nanoseconds ago, well, I need it now"
Without the buffer the drive grumbles and says oh #@#$!! and has to go fetch
it again. With the buffer, the data is stored in some RAM on the drive
electronics so that when the CPU says "OK" ready, the drive says "here you
are right in my hand" and doesn't have to go look again. The advantage is
that its a lot faster to get data from the buffer than from the disk
platters.
It works in a similar way for writing data. If the CPU can dump the data to
the drives buffer to be written when the drive is good and ready, it can say
"good, on to the next thing" instead of having to wait until the disk is
availalbe to perform the the write ....
Make sense. I hope so. At end of the day, more buffer is better for disk
intensive operations.
CJT said:A couple of embellishments -
The drive can be clever about its read buffers, and pre-load into them
sectors that haven't yet been identified as desired, but which follow ones
that have been, under the assumption that data is often read sequentially.
Write buffering has implications for error recovery --
what happens if the power fails (or the machine reboots)
while the drive's buffers are full of information that has not yet been
written to the disk?
Folkert said:Actually, it was total crap.
"it?"
They usually (or used to) call that cache.
So?
What if it is turned off and the drive's buffers are full of information
that has not yet been written to the disk?
The 'buffer' is 128kB, whether write buffering is on or off.
Dan said:Where does the ram play into this?
It depends on what you mean. With enough buffers, the computer/driveAlso just so i have it right becacue of the way buffer functions it is
something that would not affect the seek time on a hard drive
"it?"
In one case the computer to which it's attached thinks the write is done.
Dan said:So just to confirm a hard drive with a 8mb buffer and a 16mb buffer
could conceivably have the documented average seek time, while the
16mb one would be faster in real life application
Write buffering has implications for error recovery -- what happens if
the power fails (or the machine reboots) while the drive's buffers are
full of information that has not yet been written to the disk? As a
result, it is often turned off in high reliability systems.
Impmon said:There used to be an issue with earlier version of XP, the PC would
shut down so fast the data in the buffer may not have been written
yet. A patch was released long ago to put a delay and force the drive
to finish writing before shutting down.
Dan said:Now lets say you had one drive with a 16mb buffer and 12ms avg seek
time and one with 8mb buffer and a 10ms avg seek time. Which would be
better in pratical application?
Dan said:Would any of this change in the case of a laptop?
Now lets say you had one drive with a 16mb buffer and 12ms avg seek
time and one with 8mb buffer and a 10ms avg seek time. Which would be
better in pratical application?
Impmon said:seek time has little bearing these day. mS is less than a blink of
your eye.
Impmon said:seek time has little bearing these day.
mS is less than a blink of your eye.
Back in 80's, seek time used to matter a lot as they were much slower
than they are today.