Thursday, November 6, 2008

External Hard Drives Can’t be safely removed

As soon as I bought the 1TB WD My Book External hard drive, I realized the problem: it can’t be safely removed; windows states that it’s in use and any programs that use it should be closed. Not surprisingly, there is no trivial way to know what files are in use and/or what processes are locking the files.

Some googling revealed that I’m not alone on the problem, but found no solution. Some observations:

  1. Using the safely remove Hardware tray icon leads to the error message: “Windows can’t stop your ‘Generic volume’ device because it is in use. Close any programs or windows that might be using the device, and then try again later”.
  2. You go to the drive properties, go to the hardware tab, select the physical drive and click properties. In the window that appears, in Policies tab, the radio buttons are grayed out (disabled) and “Optimize for performance” is selected. It may seem that if one could change to “Optimize for quick removal” the problem would disappear.
  3. Using third party tools like the great Sysinternals Process Explorer, the cause for the problem is diagnosed as svchost.exe holding some a file named tracking.log inside System Volume Information folder. This file is running several services on the computer, so it’s difficult to solve the problem in this way.
  4. In some forums, it’s suggested that disabling the system restore on the target drive will solve the problem, but in my system it’s completely disabled.

I’m using vista business and User account Control is enabled on my system. The grayed out radio buttons were actually a side effect of this. As a workaround, you can switch to the Volumes tab, click populate, this will reopen the dialog box in elevated permissions, In this one the radio buttons are not disabled! Actually this time the “Optimize for quick removal” is selected. Microsoft has forgotten that querying or changing this option requires elevated permissions!!

I have another workaround for the original “safely remove” problem: I simply deny all users from accessing “System Volume Information” and all its contents and the problem vanishes!!!
If you need more step to step instructions: Right-Click on “System Volume Information”, Select Properties. Go to “security” tab, select “Advanced”. Go to “Owner” tab, if in Vista, Click Edit, Select Your UserName, and check “Replace owner on subcontainers and objects”. Click Ok. Close all Dialog boxes. Right Click on “System Volume Information” again and choose properties. Go to “Security”, if in vista, click “Edit”, Click “Add”, type “everyone”, click “ok”, then in “Permissions for everyone” click the topmost checkbox under “deny” column, this will select all other checkboxes in that column. Click ok.


Good luck with safe removal!!!