To understand Bad blocks, what they are, and how to check and fix errors on SSD drives, refer to the detailed content provided by Mytour below.
What is a Bad Block Error? How to Check and Fix SSD Errors
A Bad block is a multimedia storage area no longer reliable for storing and accessing data due to physical damage or errors. Additionally, Bad Block errors are also known as Bad Sectors.
There are 2 different types of Bad blocks: Bad blocks resulting from physical errors, called hard Bad blocks. And Bad blocks resulting from software errors, also known as 'soft' Bad blocks or 'logical' bad sectors, occur when the operating system cannot read data from the sector.
An example of a soft Bad block occurs when the Cyclic Redundancy Check (CRC) or Error Correction Code (ECC) for a specific storage block does not match the data read by the disk. Or encountering Bad block(s) encountered on read - continue anyway when Ghost Win operation is performed.
On HDDs, Bad blocks can occur when a location on the disk surface for writing becomes faulty or damaged. On NAND USB drives, blocks may deteriorate with use, rendering them unreliable or unusable after a certain number of write and erase cycles.
Causes of Bad Block Errors
Storage drives may develop defects during production and transportation from the factory. These bad blocks are marked as faulty before devices leave the factory and are mapped to additional memory elements of the drive.
Furthermore, a bad block can physically damage a device, rendering the operating system unable to access data. Risks such as dropping a laptop can lead to HDD failure. Natural dust and wear and tear can also cause drive errors and failures.
SSD failure occurs when the semiconductor memory cells become damaged. Storage elements may also become unreliable over time as NAND flash material within a cell may become unusable after a certain number of erase-program cycles.
The SSD erase process requires a large amount of power to pass through the flash elements. Over time, this degrades the oxide layer separating the semiconductor gates from the silicon substrate of the flash memory, leading to an increased error rate.
The drive controller may utilize error detection and correction mechanisms to fix these errors. However, at certain points, errors may exceed the controller's error correction capabilities, rendering the elements unreliable.
Soft Bad blocks occur due to software issues. For example, if the computer suddenly shuts down, the hard drive is turned off during the block write process. In this case, the block may contain data that does not match its CRC error code and is identified as a bad block.
What errors do Bad blocks cause?
When a block is faulty or damaged, it can result in errors preventing access to the stored data. If operating system or application files are stored in the faulty block, it may render the operating system or application unable to run. As the number of bad blocks increases, it consumes system capacity and space, leading to decreased drive performance and hardware failure.
Some software utilities like CHKDSK on Microsoft's Windows operating systems or badblock on Linux can scan the hard drive and mark unusable sectors that the operating system cannot utilize.
Furthermore, firmware on HDD controllers can identify and mark bad blocks as unusable. This often occurs when a block is overwritten with new data. The controller automatically remaps bad blocks to alternate sectors. Once identified as bad, that sector will not be used for future operations. Bad blocks identified during post-production drive testing are listed in the P-List, short for Permanent Error List or Primary Error List. Blocks found after drive usage, causing physical damage or reduced write surface, are recorded in the G-List, short for Grown Defect List.
When a NAND USB flash drive identifies a bad block, it is recorded in the device's Bad Block Table (BBT). Before reading from or writing to the NAND device, the controller checks the device's BBT to avoid bad blocks. Flash drives use 2 types of BBT: NAND-type that persist on boot and RAM-type BBT that is regenerated each boot.
Managing Bad Blocks
The best way to fix an HDD file affected by bad blocks is to overwrite the original file. This will cause errors leading to the hard drive remapping bad blocks or fixing CRC or data.
Managing bad blocks aims to improve the reliability and durability of NAND drives. Unlike magnetic storage media, flash drives cannot be overwritten at the byte level; all changes must be written to a new block, and data in the original block must be marked for deletion.
After a flash drive is full, the controller will begin erasing blocks marked for deletion before new data can be overwritten. To do this, it consolidates good data by copying data to a new block.
This process demands additional writes to consolidate good data, resulting in increased write amplification, meaning the actual write count exceeds the required write count. Write amplification can reduce flash drive performance and lifespan.
Flash drive manufacturers employ various techniques to control write amplification. The first technique is garbage collection, involving proactive data consolidation by releasing previously overwritten blocks. When done correctly, reallocated sectors may reduce the need to erase entire data blocks for each write operation.
Additionally, manufacturers also utilize data reduction technologies, such as compression and deduplication, to minimize the amount of data written and erased on the drive.
Furthermore, SSD interfaces can help reduce write amplification. ATA SSD TRIM commands and SAS UNMAP identify unused data blocks that can be securely erased. This approach minimizes garbage collection and frees up space on the drive, leading to improved performance.
To extend the lifespan of SSDs, controller software manages NAND devices by executing wear-leveling algorithms to distribute programming-erase (P/E) cycles across drives and ensure no block is overused compared to others. With wear-leveling, flash devices remap storage drives when writing occurs. This approach ensures even write cycles across all memory elements and prevents overwriting any block excessively, limiting errors on blocks.
To support operations like wear-leveling and garbage collection, manufacturers add unseen storage hardware to drives called overprovisioning. This provides drives with pre-allocated elements to support write operations, improving drive performance and replacing worn-out elements.
Currently, there are several best-in-class hard drive bad sector repair software like HDD Regenerator or Hard Disk Sentinel. If you're not specialized in these errors, refer to many guides on repairing bad blocks on Mytour.
So, the Mytour article has just answered your question: what is a bad block? How to check, fix errors, troubleshoot bad block on SSD drives, or fix SSD bad sectors. Hopefully, this article has provided you with useful information about bad blocks. Additionally, if you have any questions or need clarification, readers can leave their comments below the article.