Delayed file delete
Why does Win7 report that a file was deleted when it wasn't? I've had numerous instances of either installations failing, application patches crashing, and unacceptable delays during application development because Windows wasn't telling the truth about the state of a file. For instance, when the steam framework is trying to install and patch itself, part of the process is to delete the old "steam.exe" file and replace it with a new one... Windows reports that the file delete was successful when, in fact, the file is still there. The result is that the patch fails. If you watch the directory after the crash, the file will just magically delete itself a minute or so later. The only known work around in this particular case is to run in safe mode to patch... Then, this weekend, I am trying to build and debug a simple application in VS 2005 (but 2008 and 2010 also suffer this issue). about 1/3 of the time, the compiler cant copy the output file to the debug directory because (big shocker) Win7 reported that the delete worked, but it didn't actually delete the file at all and maintained a lock on it. If I wait a few minutes (taking NO OTHER ACTION) *poof* the file is gone. I have observed this on all Windows 7/Vista machines. There's even a Server 2008 install at work where this behavior caused a serious problem... I am forced to believe this is an OS issue. I don't have any anti-virus or other low level apps installed on this machine that are capable of that kind of behavior. Why does it do this? What possible good could come out of misrepresenting the file system? Can it be stopped? Thanks
June 1st, 2010 3:21am

Hi, It appears this question is about application development. Since we have specific support for this, it is recommended that you go to our MSDN forum for help: Microsoft Developer Network Forums Home Thank you for your understanding and cooperation. Hope the issue will be resolved soon. Nicholas Li - MSFT
Free Windows Admin Tool Kit Click here and download it now
June 2nd, 2010 11:12am

Hi, It appears this question is about application development. Since we have specific support for this, it is recommended that you go to our MSDN forum for help: Microsoft Developer Network Forums Home Thank you for your understanding and cooperation. Hope the issue will be resolved soon. Nicholas Li - MSFT Um, no it isn't. Nice dodge though. Here is the simple version: When I try to install application X (which I did not develop), it fails because the MSI requested a file be deleted, Vista did not delete it even though it said that it did, and the MSI subsequently could not write a new file by the name of the not-deleted file. Then, about a minute later and without any other action, the file disappears (Vista finally, and for real this time, deletes the file). I merely noted a particular use case involving three versions of another MS product. It has nothing to do with those products; this is Vista 100% (and 1000% bad). ...and when I say "Vista" I mean Windows 7 (aka Vista SP2), 64 bit.
June 2nd, 2010 10:29pm

Hi, It appears this question is about application development. Since we have specific support for this, it is recommended that you go to our MSDN forum for help: Microsoft Developer Network Forums Home Thank you for your understanding and cooperation. Hope the issue will be resolved soon. Nicholas Li - MSFT I think this is pretty funny... "Both Vista and Windows 7 seemed to introduce random delays when deleting files. For example, about one in three times when deleting the files from our filesystem benchmark, this screen below would appear and do nothing for 25-30 seconds before suddenly springing into action and deleting the files. However, this wasn't part of our benchmark, so isn't included in the numbers above." ...which came from a Linux community doing Windows7/Vista benchmarking. Seems I am not the only one.
Free Windows Admin Tool Kit Click here and download it now
June 16th, 2010 7:04am

I can verify this also happens on my computers. When an msi deletes a file, the file sometimes does not delete right away. A minute or two later, taking no action on the file, it will finally delete/disappear.
January 26th, 2011 10:21am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics