[Updated – March 2013]
Every electronic device has a set lifetime, no matter how reliable it may be. Either the mechanical components of the device fail and/or the electronics fail. It may be great news to the manufacturing companies; however not so much to us – the regular consumers.
The news of failing electronics get worse if you consider storage devices such as hard drives, SSDs, and flash memory. Drive failure frequently means loss of important data and utter disappointment. If there is a chance or restoring the data from the backup, it may take hours or even days. It’s difficult to find reconciliation, unless you’re into target practice.
It’s almost impossible to reliably predict a point of time when a drive will fail. Fortunately, there are some tools to estimate an average lifetime of a storage drive. We’ll focus on the flash memory (NAND) storage in this post, and will leave the hard drives to other blogs. Keep in mind that we’ll show a relatively simple way of computing the life of an average flash drive with typical usage.
Let’s dive in! Wait… before we do; let’s go over some basics really quickly.
- Flash memory consists of billions of transistors. Each transistor can store from one bit to three bits
- The smallest data that the flash memory can read or write is 4KB worth of data. 4KB = 32768 bits
- The smallest data the the flash memory can erase is 512KB – that’s huge!
- If the data is overwritten in the flash memory, it must first be erased and only then written.
- Each time the data is erased, the life of the transistors involved is diminished.
- Each time the data is written/read, the controller on the flash drive interacts with the flash memory. That interaction is referred to as IOPS (Input/Output [operations] Per Second)
Now we can start calculating the life of your flash drive. The usual life of each transistor for erase/write cycle is about 1,000 or less. The reason it’s not higher is because the USB flash memory makers often use MLC or TLC type flash memory. From the lesson #1 above; it is the type that stores 2 and 3 bits respectively per transistor (cell).
The average write IOPS measure for a flash drive is about 2500. However, if you’re geeky enough, you can measure yours with Intel’s iometer tool.
So how do I actually get the life of my drive?!
Previously, we used 256K data block in our calculation instead of intended 4K. The result was not a happy number! With this more appropriate computation, the 4GB gets a reputable 32.36 days of heavy duty usage!
The calculation assumes that 15% (that’s the 0.15 in computation) of the time you’ll be writing to the drive. That’s 15% of the 24 hours per day for those 32.36 days. Also, the calculation assumes that you’ll be overwriting (erasing and writing the data) evenly on the flash drive. These are 32.36 pure and hardcore writing days for a causal and even professional user.
Practically speaking, a lot depends on the usage of your drive and the capacity. Additionally, there is a hidden attribute – a factor of how well the controller on the flash drive distributes the writes. In any case, a 4GB drive can last many years. Increasing your capacity, increases the lifetime of your drive so it’s always a good idea to pick the largest size you can.
So what’s that magic number that is used in the formula, you ask? It’s quite simple 🙂 It’s purely used for conversion purposes. Since we use GBs in the numerator and seconds in the IOPS argument, it’s easier to use the 33.25 conversion factor to simplify computation. You get 33.25 with the following operation: 1,000 cycles X (1,048,576KB) / 31,536, 000 sec [There is 1,048,576KB in 1GB; there is 31,536,000 sec in one year]
So how long will your USB flash drive last? That really depends on many factors. However, there are few things you can remember if you want to extend the life of your drive.
- Buy the largest capacity you can afford.
- Do research. Choose SLC memory over MLC. And MLC over TLC.
- Avoid erasing data.
- Even the best technology fails; don’t forget to backup!
Armed with the information, you now can protect your investment better. Most of our valuable work is now stored on hard drives and flash memory. The flash memory is being utilized more and more due to its high speed and the lack of mechanical parts. However, there are important facts that you must know to better guard yourself from data loss.
[Update] We continue and expand our discussion on the endurance of flash memory here.