What Happens to Your Files on SSD?
Underline Data Storage Structure of Solid State Drive
A Solid State Drive (SSD) is a much faster storage device than a normal hard drive you use.
Do you know that the size of data affected by a single delete operation on an SSD is more than its write operation? Don’t get confused! It does not mean that your files grow inside an SSD ;-)
To understand that, you first need to know what package, die, plane, block and page mean.
A Typical SSD would look similar to the following image. The black chips you see are called packages. They are memory chips.
- Inside each package contains one or more (i.e. 1, 2, 4…) dies. They are the smallest units that can independently execute commands or report status.
- Each die contains one or more planes (usually one or two). Identical, concurrent operations can take place on each plane, although with some restrictions.
- Each plane contains a number of blocks, which are the smallest unit that can be erased.
- Each block contains a number of pages, which are the smallest unit that can be programmed (i.e. written to). Typically a page contains 4KB, 8KB or 16KB (determined by design).
When a write operation takes place it would affect only a page (about 4 to 16 kilobytes). However, a delete operation would affect an entire block which typically 128 or 256 pages (about 0.5 to 4 megabytes). That gives the explanation to the first question.
So, when I delete a file, wouldn’t it delete block/s where other files might have kept data? Well, No! There is a difference between you pressing “Delete” button and internal delete operation of SSD.
When you press “Delete” button, only the link (pointer) connecting the file inside OS and the physical location of the data would be removed. Actual deletion would be handled by Flash Translation Layer which I would describe in another post.
In this post, I wanted to educate you on how our files are stored on a SSD. Let me assume you perfectly understand all this ;-) Thanks for reading!