logo elektroda
logo elektroda
X
logo elektroda
Dostępna jest polska wersja

Czy wolisz polską wersję strony elektroda?

Nie, dziękuję Przekieruj mnie tam

How to recover data from failed hard drive: HDD, SSD, ddrescue, TestDisk

User question

how to recover data from failed hard drive

Artificial Intelligence Response

Direct answer to the question

To recover data from a failed hard drive:

  1. Stop using the drive immediately.
  2. Do not format it, initialize it, run CHKDSK on it, reinstall Windows, or copy files onto it.
  3. Determine whether the failure is logical or physical.
  4. If the drive is clicking, grinding, beeping, not spinning, or not detected in BIOS/UEFI, power it off and consider a professional data recovery lab.
  5. If the drive is still detected, the safest DIY method is:
    • Clone/image the drive sector-by-sector with GNU ddrescue.
    • Work only on the clone/image.
    • Use tools such as TestDisk, PhotoRec, R-Studio, UFS Explorer, DMDE, Recuva, etc., to recover files.

The most important rule: recover from a clone, not directly from the failing drive.


Detailed problem analysis

1. Identify the type of failure

Hard drive failures usually fall into these categories:

Failure type Typical symptoms DIY recovery?
Logical failure Drive detected, partition missing, RAW file system, deleted files, accidental format Often possible
Bad sectors / weak media Drive detected but very slow, read errors, freezes during copy Possible, but clone first
Electrical / PCB failure No spin, no detection, burnt smell, visible PCB damage Sometimes, but risky
Mechanical failure Clicking, grinding, beeping, spin-up/spin-down loop Usually professional only
Firmware failure Detected as 0 bytes, wrong model, hangs BIOS/UEFI Usually professional only

If the drive makes repetitive clicking, knocking, scraping, or grinding sounds, stop powering it. Those symptoms may indicate head or platter damage; repeated power-on attempts can make recovery much harder or impossible.


2. What not to do

Avoid these common mistakes:

  • Do not run CHKDSK, fsck, Disk Utility repair, or “repair partition” tools on the original failing drive.
    CHKDSK is designed to check and repair file-system errors, but repair operations can modify metadata; use it only on a clone if data recovery is the goal. Microsoft documents CHKDSK as a tool that can fix logical disk errors when repair options such as /f are used. (learn.microsoft.com)

  • Do not format the drive, even if Windows says “You need to format the disk before you can use it.”

  • Do not initialize the disk in Windows Disk Management.

  • Do not install recovery software onto the failed drive.

  • Do not save recovered files back to the same failed drive.

  • Do not open the hard drive casing.
    HDD platters and heads require a cleanroom environment. Dust contamination can cause additional head crashes.

  • Do not use the freezer method.
    This old trick is unsafe for modern high-density drives because condensation and mechanical stress can worsen damage.


Practical recovery workflow

Step 1: Check whether the drive is physically alive

Connect the drive as a secondary drive to another computer if possible.

For SATA HDDs:

  • Use a known-good SATA data cable.
  • Use a known-good SATA power connector.
  • Prefer direct motherboard SATA connection over USB if the drive is unstable.

Check:

  • Does it spin?
  • Is it detected in BIOS/UEFI?
  • Does it show the correct model and capacity?
  • Does it make unusual noises?

If it is not detected at all, or it is clicking/grinding, skip DIY software recovery and go to a professional lab.


Step 2: If detected, clone it first with ddrescue

For a failing drive, ordinary copy tools are poor because they often stop on read errors. GNU ddrescue is designed for this situation: it copies readable areas first, skips bad regions, and uses a map file so recovery can be resumed and retried efficiently. (gnu.org)

You need:

  • A Linux live USB, such as Ubuntu.
  • A destination disk at least as large as the failed drive.
  • Enough time; recovery can take hours or days.

Boot Linux and identify disks:

lsblk -o NAME,SIZE,MODEL,SERIAL

Be extremely careful identifying the failed source drive and the healthy destination drive.

Example:

  • Failed drive: /dev/sdX
  • Destination drive: /dev/sdY
  • Map file: rescue.map

First pass: copy good sectors quickly, skip bad areas:

sudo ddrescue -f -n /dev/sdX /dev/sdY rescue.map

Second pass: retry bad areas:

sudo ddrescue -f -d -r3 /dev/sdX /dev/sdY rescue.map

Important:

  • /dev/sdX = failed source drive.
  • /dev/sdY = healthy destination drive.
  • The destination drive will be overwritten.
  • Keep the rescue.map file; it lets ddrescue resume without starting over.

You can also clone to an image file:

sudo ddrescue -n /dev/sdX /mnt/recovery/failed_drive.img /mnt/recovery/rescue.map
sudo ddrescue -d -r3 /dev/sdX /mnt/recovery/failed_drive.img /mnt/recovery/rescue.map

After cloning, disconnect the original failed drive and work only on the clone or image.


Step 3: Recover partitions or files from the clone

Once you have a clone, choose the correct recovery method.

Case A: Partition is missing or drive appears as RAW

Use TestDisk.

TestDisk is intended for recovering lost partitions and repairing boot/partition structures. Its companion tool PhotoRec is used when file-system structure is too damaged and files must be recovered by signature scanning. (photorec.dev)

General TestDisk workflow:

  1. Run TestDisk as administrator/root.
  2. Select the cloned disk or image.
  3. Choose partition table type, usually:
    • Intel/MBR for older disks,
    • EFI GPT for modern disks.
  4. Choose Analyse.
  5. Run Quick Search.
  6. If needed, run Deeper Search.
  7. If the correct partition is found, copy files out or cautiously restore the partition table on the clone.

Do not write repaired partition structures to the original failed disk.


Case B: File system is badly damaged

Use PhotoRec or a commercial file recovery tool.

PhotoRec performs file carving: it scans raw sectors for known file signatures. This can recover files even when the file system is corrupted, but it often loses original filenames and folder structure. The official documentation notes that PhotoRec can recover files from corrupted file systems, but not necessarily original names or directory structure. (cgsecurity.org)

Use PhotoRec when:

  • The partition table is gone.
  • The file system is RAW.
  • TestDisk cannot rebuild the partition.
  • You mainly need documents, photos, videos, archives, etc.

Recover files to a different physical drive, never to the clone being scanned.


Case C: Deleted files or accidental format

If the drive is healthy and the issue is deletion/formatting:

  • Clone first if the data is important.
  • Then use recovery software on the clone.
  • For simple deleted files on Windows, tools like Recuva may work.
  • For serious recovery, tools such as R-Studio, UFS Explorer, DMDE, GetDataBack, or PhotoRec are stronger choices.

The less the disk has been used since deletion/formatting, the better the chance of recovery.


Physical failure scenarios

Clicking or knocking HDD

Likely causes:

  • Failed read/write heads.
  • Head crash.
  • Damaged service area.
  • Platter surface damage.

Action:

  • Power off immediately.
  • Do not keep retrying.
  • Do not open the drive.
  • Use a professional data recovery service if the data matters.

Drive spins but is not detected

Possible causes:

  • Firmware failure.
  • Bad heads.
  • PCB issue.
  • Damaged service area on platters.

This is often beyond normal software tools. Professional labs use hardware imagers and vendor-specific repair systems to stabilize the drive before imaging.

Drive does not spin at all

Possible causes:

  • Failed PCB.
  • Shorted TVS diode.
  • Blown fuse/zero-ohm resistor.
  • Seized spindle motor.

A technically skilled person may inspect the PCB, but PCB swaps are not simple on modern drives. Many HDDs store unique calibration/adaptive data in ROM or flash on the PCB. A donor PCB often requires ROM transfer or firmware adaptation.

If the data is valuable, professional recovery is safer.


SSD note

If the “hard drive” is actually an SSD, the approach changes.

SSD failures often involve:

  • NAND degradation.
  • Controller failure.
  • Firmware panic state.
  • Flash translation layer corruption.
  • Built-in hardware encryption.

With SSDs, chip-off recovery is much harder than with older flash devices because data may be encrypted, wear-leveled, compressed, and interleaved across NAND packages. If an SSD is not detected or shows an incorrect capacity, professional recovery is usually the best option.

Also, deleted files on SSDs may be unrecoverable if TRIM has erased the blocks.


Current information and trends

The current best-practice workflow remains:

  1. Minimize power-on time.
  2. Clone/image first.
  3. Analyze the clone.
  4. Use file-system recovery or file carving tools.
  5. Escalate physical, firmware, and SSD controller failures to specialists.

GNU ddrescue remains one of the standard tools for unstable media because its map-file-based workflow avoids repeatedly rereading known-good areas and allows interrupted recovery sessions to resume efficiently. (gnu.org) TestDisk and PhotoRec remain widely used open-source tools for partition recovery and file carving. (photorec.dev)


Practical guidelines

Minimal safe DIY path

Use this sequence:

  1. Stop using the failed drive.
  2. Check symptoms.
    • Clicking/grinding/not detected: professional lab.
    • Detected but unreadable: continue.
  3. Connect to another computer as a secondary drive.
  4. Clone with ddrescue.
  5. Disconnect the original.
  6. Run TestDisk on the clone if partitions are missing.
  7. Run PhotoRec or other recovery software if the file system is badly damaged.
  8. Save recovered files to a third drive.
  9. Verify recovered files before reusing or discarding anything.

Good recovery storage setup

Ideally have:

  • Original failed drive.
  • Destination clone drive of equal or larger capacity.
  • Separate recovery output drive.
  • Optional additional backup of the clone image.

Example:

Failed HDD ---> Clone HDD/Image ---> Recovery software ---> Recovered files on third disk

When to stop DIY

Stop and use a professional recovery service if:

  • The data is irreplaceable.
  • The drive clicks, grinds, buzzes, or spins down repeatedly.
  • The drive is not detected in BIOS/UEFI.
  • The drive reports 0 bytes or wrong capacity.
  • ddrescue cannot read meaningful data.
  • You are unsure which disk is source and which is destination.
  • The drive was dropped, flooded, burned, or exposed to electrical damage.

DIY attempts can reduce the odds of professional recovery if the problem is mechanical.


Ethical and legal aspects

Only recover data from drives you own or are authorized to access. If the drive contains business, medical, legal, or personal data belonging to someone else, preserve chain of custody and avoid altering the original media. In professional environments, image the drive first and document every action.


Brief summary

For a failed hard drive, the safest approach is:

  • Stop using it.
  • Do not repair or format it.
  • If it has physical symptoms, power it off and use a professional lab.
  • If it is detected, clone it with ddrescue.
  • Recover files from the clone using TestDisk, PhotoRec, or professional recovery software.
  • Never recover files back onto the same drive.

If you tell me the exact symptoms — HDD or SSD, internal or external, detected or not, any noises, operating system, and what Disk Management/BIOS shows — I can give you a more specific recovery plan.

Ask additional question

Wait...(2min)
Disclaimer: The responses provided by artificial intelligence (language model) may be inaccurate and misleading. Elektroda is not responsible for the accuracy, reliability, or completeness of the presented information. All responses should be verified by the user.