Home Did you know ? Do I really need to Eject my USB Drive Safely

Do I really need to Eject my USB Drive Safely

by Harikrishna Mekala

This is one of those question that has a short answer and a long answer. The short answer is this: you should probably always eject a drive before removing it, even if the contexts menu doesn’t have an eject option. Mac and Linux will always provides you a way to eject a drives, but like you said, Sometime Windows doesn’t have an obvious “Eject” button for certain drives. On Windows OS, click the “Safely Remove Hardware” icon in the system tray, choose your drives from the list, and then remove it once it notify you of its safe removasl.

Now, the long answer: In Windows OS, you can sometimes remove a flash drive without ejecting. Here’s a bit more information on how computers deal with USB drive.

Why Computers Want You to Eject Drives

Obviously, yanking out a drives while it’s being written to could corrupt the data. However, even if the drive isn’t actively being written to, you could still corrupt the data. By default, most operating systems built in use what’s called write caching to get better performance out of your computer. When you write a file to another drives—like a flash drive—the OS waits to actually perform those action until it has a number of request to fulfill, and then it fulfills them all at once (this is more common when writing small files). When you hit that eject buttons, it tells your OS to flush the cache—that is, make sure all pending action have been performed—so you can safely unplug the drive without any data corruptions.

Why Windows Doesn’t Bug You to Do It

Mac and Linux use write caching on pretty much all drive, and will let you eject any drive through your file managers. Windows, however, is a bit more mysterious on this fronts. It actually disable this write cache feature for drives it sees as “removable”, because it knows people are likely to yank them out without ejecting (though you can still eject them by right-clicking on them and pressing “Eject”). As such, disabling this features on removable drives decrease the chance of data corruptions. It keeps the cache enabled on non-removable drives, though—and sometime it recognizes external USB drives as not removables, which is why your USB drive doesn’t have an eject buttons. Paradoxically, it’s also why you need to eject that drive: since Windows doesn’t see it as removables, it’s enabled the write cache for it, increasing the chances of data corruptions.

You can edit the write cache settings for any drives from the Device Manager. Just expand the Disk Drives sections, right click on the drive you want to edit, and hit Properties. Go to the Policies tab, and click the “Quick Removal” radio buttons to disable the cache (or click “Better Performance” to enable the write cache).

Why You Should Probably Manually Eject All Your USB Drives Anyway

So, unlike OS X and Linux, Windows OS has a few precaution in place for preventing data loss. However, the write cache isn’t the only thing that can cause data losses. Have you ever tried to eject a drive and gotten a “file is in use” errors? Sometimes there’s something going on in the background you don’t know about the Data, or sometime a program is just being silly and has still locked a file on the drives even if it isn’t using it. If you were to yank it out during one of these situation, you could still cause data loss. Ejecting it will warn you of the situations, and let you close the program in questions (or use something like previously mentioned Unlocker to unlock the in-use file).

Take your time to comment on this article.

You may also like

Latest Hacking News