14

Does Windows flush the drive caches when entering standby mode?

It seems like an obvious thing to do and I for one would design it like that if I were on the Windows team, but over the years, I have learned not to make such assumptions.

I only managed to find a single page that asked this (in regards to XP), but no answer was given, just a generic response.

Is there any sort of definitive information that Windows flushes disk caches on standby?

5
  • "On standby?" Or "before going to standby?" Jul 25, 2012 at 15:40
  • I assumed that is what you meant, but the verbiage wasn't clear. Jul 25, 2012 at 15:41
  • Going obviously; it’s suspended during standby. (I assumed from the context, and the usage of on rather than during that it was clear that I used the term as a verb, not an adjective.)
    – Synetech
    Jul 25, 2012 at 16:05
  • I have always wondered this. I always assumed it was safe because there was no I/O to the flash drive, so I'm curious as to what the answer is. Jul 25, 2012 at 16:59
  • Wow, someone must be bitter and petty to have down-voted and run. (Don’t worry Jason, I know it wasn’t you.)
    – Synetech
    Jul 25, 2012 at 17:57

2 Answers 2

7

The answer is yes according to this MS Support article + some "Sherlock Holmes deductions":

The FLUSH CACHE command is not issued and the hard disk may become corrupted when you enter standby or hibernate

MSKB 331060

This article apply to Microsoft Windows XP Service Pack 2 and MS issued an HotFix to correct the problem therefore we can assume (!? ;) ) that a Flush Cache Command is issued each time Windows XP (an later?) enter in standby mode. I found no other article issued by MS to clarify this point but this is the well known obscure MS communication style...

2
  • +1 Okay, then I guess XP SP3 and up (and SP2 with the appropriate patch), it can be assumed that it does. I’m curious however, why they felt the need to specifically state the the problem applies to “large hard disk that has a 48-bit logical block address (LBA) enabled”. Does that mean that it does flush small hard-drives, flash-drives, memory-cards, etc.? Unfortunaetly like you said, Microsoft is usually “clear as mud”. :-|
    – Synetech
    Jul 26, 2012 at 0:21
  • 1
    @Synetech: It's an implementation detail. Not everything is documented to prevent developers from creating dependencies on behaviors that may change in the future.
    – surfasb
    Jul 26, 2012 at 2:32
2

It depends on the hardware settings for the drive.

A drive that Windows recognizes as a removable drive by default has the write cache turned off, which generally makes it safe to remove without "ejecting" the drive.

http://lifehacker.com/5863810/do-i-really-need-to-eject-usb-drives-before-removing-them

Hope that helps.

4
  • 1
    Yes, I’m familiar with that setting, but it doesn’t explain Windows’ specific policy on flushing caches on standby.
    – Synetech
    Jul 25, 2012 at 16:05
  • 4
    If the cache is turned off though, is there a cache to flush? Jul 25, 2012 at 16:31
  • Are you assuming that there is only one removable drive? Did you read the page that you linked to? It clearly says that it is recommended to eject drives even when they are set to quick-removal. Who says the drive is set to quick-removal anyway? If you need it, mentally edit my question to be specifically about drives that are not set to quick-removal. In fact, forget about flash-drives altogether, read the question as does Windows flush internal, non-removable, hard-drive caches when entering standby?
    – Synetech
    Jul 25, 2012 at 16:57
  • I don’t know why this was up-voted, it absolutely has nothing to do with the question at hand.
    – Synetech
    Jul 25, 2012 at 17:25

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .