Hard Drive Bad Sector Mapping

It is a fact of hard disk drive manufacture, that no matter how well prepared the platters are, defects causing bad sectors will always be an issue at some point during their lifespan.  It is important to locate any bad sectors when the hard disk drive is factory formatted, and keep track of any which occur during use.

The location of all bad sectors is important for data recovery purposes, especially those detected during the factory format process. Each hard disk drive also contains a set of spare sectors, which are used to remap bad sectors detected during normal operation. The hard drive firmware usually handles this process automatically, but rare instances a failure can damage this information, which had serious consequences when performing a data recovery.

Factory Format Primary Defect List (P-List)

During the factory format process, any bad sectors detected, are stored in an area called the P-List. This list maps a shift pattern for each bad sector, which is used to ensure that the correct sectors are always accessed. A failure of the P-List would cause the incorrect sectors to be accessed, leading to data corruption, as additional sectors may be inserted into the data image. Fortunately this is very rare, and usually only occurs through the result of bad firmware and excessive heat damage.

If during the factory format process, physical sector 10 was bad, it would be placed into the P-List, and logical sector 10 would point to physical sector 11 on the platter. Each bad sector shifts the difference between the logical and physical sector by one for each defect found.

Dynamic Bad Sector Grown Defect List (G-List)

During normal operation, any bad sectors which are detected will be mapped out to a spare sector, the location of which is stored in the G-List. This is a normal part of the operating procedure for a hard disk drive, and no data is normally lost when this occurs.

There are however, only a finite number of spare sectors available, so eventually these will be used up. Once this happens, any bad sectors subsequently detected, will not be swapped out, and their presence must be reported to the host operating system.

Data Recovery Bad Sector Implications

It is rare for the either of these lists to become corrupted or lost, but the consequences could be serious, particularly if the P-List is damaged. For the purposes of data recovery, this would cause the raw data image to become shifted for each incorrectly indicated bad sector in the P-List. The implications of such a failure are serious for the purposes of data recovery, as the underlying file system structures would not occur in the correct positions.

A failure of the G-List would only result in the loss of each sector, or in the worst cases, old data being read from the original location. The hard disk drive manufacturers therefore have a duty of care, to ensure that this does not occur, as a large scale problem with any type of hard disk drive would have a serious impact on their reputation and the future of the company.

Comments are closed