Sector-by-Sector Clone
A sector-by-sector clone copies every byte of a drive, including bad-sector regions, deleted file remnants, and unallocated space that standard file copy tools never see. The principle behind it is simple: read the failing drive once and recover from the clone repeatedly. Every additional read on a failing drive accelerates the failure; the clone protects the source while letting you try multiple recovery approaches against the same data.
Datarecovery.com · Data-Medics
Retrying · Multi-pass
Modern ddrescue practice
A sector-by-sector clone (also called a bit-by-bit clone, raw clone, or forensic image) is a complete copy of a storage drive that captures every individual sector regardless of whether it contains visible files, deleted files, or empty space. The clone is identical to the source at the byte level, including unallocated regions, slack space, file-system metadata, and any data hiding outside the visible file structure. Unlike standard file-level copies that read drives through the operating system’s file system layer, sector-by-sector clones read the raw storage directly.
What Sector-by-Sector Cloning Actually Is
A standard file copy operation works at the file system level: the operating system sees a list of files, you select some of them, and the OS copies their contents to a destination. Sector-by-sector cloning works one layer below: it copies every storage sector on the drive in order, regardless of what (if anything) the file system thinks is there.1
What gets copied
A complete sector-by-sector clone preserves everything the source drive contains:
- All visible files in their exact on-disk locations.
- Deleted files still present in unallocated space until they’re overwritten.
- Slack space inside file allocations where old data lingers in unused parts of the last cluster of each file.
- File system metadata: the Master File Table, partition tables, boot sectors, and directory structures.
- The boot record itself, including bootloader code and partition table.
- Hidden partitions and recovery partitions that may not be visible through the OS.
- Bad sector regions with whatever content can be read from them.
The result is a copy that is functionally identical to the source. Mounting the clone or analyzing it with recovery software produces the same results as analyzing the source directly, except the source no longer has to be touched.
Sector-by-sector clone vs disk image
The terms overlap in usage. A disk image is the artifact: a file (or sometimes a destination drive) that contains the byte-for-byte copy. A sector-by-sector clone is the process of producing one, specifically using techniques that handle bad sectors and preserve every byte. Every recovery-grade disk image is the result of a sector-by-sector clone operation; the process is what produces the artifact. The two terms are often used interchangeably, but the distinction matters when you’re describing what to do versus what you have.
The image-once-recover-repeatedly principle
The technique exists because of a fundamental property of failing drives: every read accelerates the failure. The Technibble forum thread captures this directly: you should never read a single sector on a hard drive more than once.2 Cloning forces a single, well-organized read pass that captures everything. After cloning completes, all subsequent recovery work happens against the clone, which is on a healthy destination drive. The failing source can be powered off and stored without further stress.
Why Standard File Copy and Cloning Tools Fail
Most users have copied files between drives countless times. Why doesn’t ordinary copying work for recovery? Two reasons: standard tools don’t read what’s invisible to the file system, and they fail catastrophically when they hit a bad sector.3
File copy doesn’t see deleted data
When you copy a file in File Explorer or Finder, the operating system reads only the file’s allocated sectors as listed in the file system metadata. Deleted files that haven’t been overwritten still exist on disk but aren’t visible to file copy tools. The same applies to slack space, metadata regions, and any data outside the file system’s tracked allocations. For recovery purposes, those invisible regions often contain the data you need: deleted files, file-system journals showing recent activity, partition tables for partitions that have been removed.
Standard cloning tools abort on errors
Tools like Windows’ built-in disk-cloning utilities, basic cp commands, or even more sophisticated cloning tools like Macrium Reflect or Acronis True Image are designed for healthy drives. When they encounter an unreadable sector, they typically abort the entire operation rather than skipping the bad sector and continuing. A drive with even one bad sector in an inconvenient location can defeat these tools entirely.4
Standard tools don’t log failures
Even when standard tools do skip errors, they don’t usually log which sectors failed in a way that lets recovery resume from where it stopped. Recovery-grade tools maintain a mapfile that records every failed sector range. The mapfile is what makes multi-pass recovery possible, since each pass can target only the sectors that previous passes failed to read, without redoing already-completed work.5
The Windows-host-controller problem
Even when recovery-grade Windows tools exist, they share a fundamental limitation: the Windows host controller doesn’t allow software to control ATA commands directly. Read timeouts, retry counts, and similar low-level parameters are managed by the OS, not the application. For failing drives where you specifically want fast timeouts (so the drive doesn’t lock up retrying a bad sector for 30 seconds), this matters. Linux-based tools have direct hardware control and can configure these parameters, which is why ddrescue running on a Linux live USB outperforms most Windows-based recovery cloning even when the Windows tool is well-designed.
Comparison: standard copy vs recovery clone
| Capability | File copy / standard cloner | Sector-by-sector clone (ddrescue) |
|---|---|---|
| Captures visible files | Yes | Yes |
| Captures deleted files in unallocated space | No | Yes |
| Captures slack space content | No | Yes |
| Continues past bad sectors | Usually no | Yes |
| Logs which sectors failed | No | Yes (mapfile) |
| Resumable across multiple sessions | No | Yes |
| Direct ATA command control | No (on Windows) | Yes (on Linux) |
| Configurable read timeouts | No | Yes |
How ddrescue Works: The Multi-Phase Algorithm
GNU ddrescue is the standard tool for software-based sector-by-sector cloning of failing drives. Its algorithm is sophisticated in ways that matter for recovery success.6
The five phases
ddrescue divides its work into distinct phases, each targeting a different stage of the recovery:
- Copying phase: reads non-tried parts of the input in large blocks, marking blocks that fail as non-trimmed and skipping past them quickly. Up to five passes, with direction reversed after each pass to delimit large bad areas efficiently. The goal is capturing readable data before damage progresses.
- Trimming phase: reads sector by sector at the edges of failed blocks to determine the precise boundaries between readable and unreadable regions. This shrinks the damaged areas in the mapfile and recovers data adjacent to bad sectors that the first pass skipped past.
- Scraping phase: reads the remaining non-scraped blocks one sector at a time. Any sectors that still fail are marked as bad-sector. This recovers what’s possible from blocks the trimming phase couldn’t fully resolve.
- Retrying phase: retries known bad sectors until either they succeed or the configured retry limit is reached. The direction reverses on each retry pass.
- Final mapfile: after all phases complete, the mapfile shows exactly what was recovered, what failed, and the precise sector ranges of each.
The mapfile is the key
The mapfile (sometimes called the logfile) is what makes ddrescue uniquely effective for recovery. It’s a text file recording every sector range and its status: copied successfully, skipped, marked as bad, or not yet tried. The Data-Medics guide describes it precisely: it should arguably be renamed since it’s not really a log of activity but a sector-status database.7
The mapfile enables several capabilities that are otherwise impossible:
- Resume interrupted operations: if power fails or you stop ddrescue, the next run picks up exactly where the previous one stopped.
- Multiple recovery sessions: you can power off the drive, let it cool down for hours, and resume; ddrescue uses the mapfile to skip already-completed regions.
- Reverse-direction passes: the
-Rflag tells ddrescue to read backwards, which sometimes succeeds where forward reads fail because the drive’s controller approaches problem regions from a different angle. - Retry only bad sectors: after an initial pass, you can rerun with
--cpassto retry only the failed regions without redoing successful regions.
A typical first-pass command
A reasonable first-pass invocation for an unknown failing drive:
ddrescue -d -n -b 4096 /dev/sdX drive.img drive.mapfile
The flags are tuned for a fast first pass that captures readable data quickly:
-duses direct disk access, bypassing the OS cache for accurate reads.-nskips the trimming and scraping phases on the first run; the goal is rapid capture of readable data, with detailed work on bad regions deferred to a second pass.-b 4096sets a 4K block size, matching modern Advanced Format drives./dev/sdXis the source drive (replace X with the actual letter; verify withlsblkfirst).drive.imgis the destination image file.drive.mapfileis the mapfile.
The retry-flag debate
Many tutorials recommend using -r3 (retry bad sectors three times) or even higher retry counts on the first pass. Datarecovery.com explicitly recommends against this: forcing a malfunctioning drive to read damaged areas without first having it diagnosed by a professional can cause further damage, including potential head-stack failure on HDDs.8 The conservative practice for unknown failure modes is: skip retries on the first pass, get the bulk of the readable data captured, then evaluate whether to retry bad sectors based on how much data was actually missed and how the drive is behaving. If the drive is making unusual sounds or its read-error rate is increasing, more retries can convert a partially-recoverable case into a fully-unrecoverable one.
Hardware Imagers vs Software Tools
ddrescue is the best free software-based sector-by-sector cloning tool, but it’s not the only or most powerful option. Professional recovery services use hardware imagers that can do things software running on a PC cannot.9
Software-only options
- GNU ddrescue: the free open-source standard, runs on Linux and macOS. Sophisticated multi-phase algorithm with mapfile support. Best free option for most cases.
- HDDSuperClone: commercial software that improves on ddrescue’s algorithm specifically for failing drives, with better handling of drives that disconnect during operation.
- Atola Insight Forensic (software mode): commercial forensic-grade software with advanced features for drives that don’t quite need full hardware imaging.
- R-Studio Drive Image: commercial software with sector-by-sector cloning built into a broader recovery toolkit.
Hardware imagers
For drives that are too damaged for software cloning, professional hardware imagers provide capabilities at a level above what software can achieve:
- PC-3000 (ACE Lab): the dominant professional recovery hardware, capable of imaging drives that disconnect repeatedly, drives with firmware corruption, and drives that don’t respond to standard ATA commands. Includes vendor-specific firmware repair tools.
- DeepSpar Disk Imager (DDI): hardware imager focused on recovery from drives with bad sectors and degraded firmware, with configurable per-sector timeouts and intelligent skip patterns.
- Atola Insight Forensic (hardware): hardware imager combining recovery and forensic capabilities, with hash verification and chain-of-custody logging for legal cases.
When hardware imagers are necessary
Hardware imagers cost in the high four to five figures and require specialized training. They’re justified when:
- The drive disconnects from the host repeatedly during cloning, making software-based recovery impossible.
- The drive has firmware corruption that prevents normal ATA communication.
- The drive’s internal heads are partially failing and need configurable read parameters to capture data before complete failure.
- Forensic chain-of-custody requirements demand hash verification and write-blocking that consumer hardware can’t reliably provide.
- The case involves an SSD with controller failure that needs the controller bypassed entirely (chip-off recovery starts with hardware imaging of the NAND chips).
When and How to Use Sector-by-Sector Cloning
Sector-by-sector cloning isn’t appropriate for every recovery scenario. Knowing when to clone and when to skip directly to recovery saves time on healthy drives and protects data on failing ones.
When cloning is essential
- Failing drives: any drive showing bad-sector counts, intermittent errors, unusual sounds, or rising SMART warnings should be cloned before recovery is attempted.
- Drives with critical data: if losing the data would be catastrophic, clone first regardless of the drive’s apparent health. The clone is cheap insurance against a recovery operation going wrong.
- Drives where multiple recovery approaches will be tried: if you’re going to run TestDisk, then PhotoRec, then a commercial recovery tool, working from a clone means each tool sees the same starting state.
- Drives in hybrid damage scenarios: physical damage producing logical symptoms benefits enormously from imaging first; the logical recovery happens against the image while the failing source is left alone.
- Drives heading to professional services: recovery labs prefer to receive a clone or to clone the drive themselves; avoid running recovery software directly on a drive you’re going to send for professional recovery.
When cloning isn’t necessary
- Healthy drives where you want to recover deleted files: if the drive is mechanically sound and SMART data is clean, running recovery software directly is acceptable and faster than cloning.
- Time-critical scenarios where the drive is healthy: recovery software can find and copy files in less time than cloning would take, when the drive’s health doesn’t add to the risk.
- Drives where the destination capacity isn’t available: cloning requires a destination at least as large as the source. Without that, work directly with the source if it’s healthy or escalate to professional services if it isn’t.
Sector size and destination compatibility
One subtle issue affects clones to physical destination drives: modern drives use different sector sizes that aren’t always interoperable. 512-byte native (512n) drives expose 512-byte sectors. 512-byte emulated (512e) drives have 4K physical sectors but emulate 512-byte sectors for compatibility. 4K native (4Kn) drives expose 4K sectors directly. Cloning a 512n source to a 4Kn destination produces an unbootable result because the partition table assumes the wrong geometry. Imaging to a file rather than another drive avoids this entirely; the image file holds whatever sector size the source had, and recovery tools work correctly against it.
Step-by-step workflow
- Identify the failing drive’s device path with
lsblkon Linux. Confirm the destination drive or file location. - Run a fast first pass with
-nto capture readable data quickly without lingering on bad sectors. - Review the mapfile to see how much was captured and where the remaining bad regions are.
- Decide on retry strategy based on how the drive is behaving. If the drive sounds healthy and only minor regions failed, run a retry pass. If the drive is making unusual sounds, stop and consult a professional.
- Run additional passes if appropriate, including reverse-direction reads with
-Rfor stubborn regions. - Verify the image by mounting it (read-only) or running file system checks against it before starting recovery work.
- Power off the source drive and store it; all subsequent work happens against the image.
Sector-by-sector cloning is the single most important technique in data recovery because it changes the structure of the recovery problem. Without cloning, every recovery attempt is a one-shot operation against a degrading source; with cloning, recovery becomes an iterative process against a stable copy. The difference matters enormously when the first recovery attempt doesn’t get everything you need, when you want to try a second tool, when the recovery operation itself produces errors that need investigation, or when you want to send the drive to a professional service after attempting DIY recovery.2
The most common DIY recovery failure mode isn’t choosing the wrong recovery software; it’s running recovery software directly against a failing drive without cloning first. The recovery scan reads every sector, the failing drive degrades during the scan, and by the time the scan finishes, the drive is in worse condition than when it started. A second recovery attempt then operates on a more-degraded source, often producing worse results than the first. By the third attempt, the drive may be unrecoverable. Cloning to a known-good destination breaks this cycle: the source is read once, the destination is stable, and recovery work happens repeatedly against the stable copy.
For users facing data loss, the practical framework is: if the drive shows any signs of physical health issues, clone first. If the data is critical and the drive is healthy, clone first as insurance. If the drive is healthy and the data is replaceable, you can skip cloning. Recovery software works best when applied to a stable, complete copy rather than a failing source. The relationship between cloning and recovery is hierarchical: cloning is the foundation, recovery is the operation built on top. Skipping the foundation often means the building doesn’t stand.
Sector-by-Sector Clone FAQ
A sector-by-sector clone is a complete byte-for-byte copy of a storage drive that captures every sector regardless of whether it contains visible files, deleted files, or empty space. The clone is identical to the source at the lowest level: same file system structures, same deleted files in unallocated space, same slack space inside file allocations, same boot sectors and partition tables. Standard file-copy operations only read files visible through the file system; sector-by-sector cloning reads the raw storage directly. This makes the technique essential for data recovery scenarios where the visible file structure doesn’t represent everything that’s recoverable from the drive.
Both tools create sector-by-sector clones, but they handle errors very differently. The dd command aborts when it encounters a read error, leaving everything after the error point uncopied. This makes dd unsuitable for failing drives. The ddrescue command (sometimes called gddrescue) is purpose-built for failing drives: it skips bad sectors during the first pass to capture readable data quickly, logs which sectors failed in a mapfile, then returns to retry the bad sectors in subsequent passes. The mapfile lets ddrescue resume interrupted operations and run multiple recovery attempts against the same drive without redoing work that’s already complete. For any failing drive, ddrescue is the right choice; dd is only appropriate for healthy drives where speed matters and read errors aren’t expected.
Two reasons. First, failing drives degrade further with each read attempt; running recovery software directly on a failing drive can mean dozens of full-disk scans, each one accelerating the failure. Cloning once and recovering repeatedly from the clone protects the source. Second, recovery operations sometimes write data back to the drive (file system repair tools, partition rebuilds, or just retry attempts that overwrite metadata). Working from a clone means the source is never modified, so multiple recovery approaches can be tried without each one risking the previous attempt’s results. The principle is: read the drive once, recover from the clone repeatedly.
For free, software-based cloning, ddrescue running on Linux is the standard tool. SystemRescueCD or any Linux live USB provides ddrescue and the necessary environment without installing anything to the failing computer. For Windows users, ddrescue can run via Cygwin or WSL, though Linux native is more reliable. For commercial software-only options, HDDSuperClone improves on ddrescue’s algorithm specifically for failing drives. For professional-grade hardware imaging, PC-3000, DeepSpar Disk Imager, and ATOLA Insight provide capabilities that go beyond software cloning, including direct ATA command control, configurable read timeouts, and the ability to handle drives that would disconnect from a standard USB or SATA interface.
For a healthy drive, cloning is limited by the slower of read and write speeds; a 1 TB drive cloning at 100 MB/s takes about 3 hours. For failing drives, the time can extend dramatically depending on how many bad sectors exist. Drives with localized damage may complete in slightly more time than a healthy drive. Drives with extensive bad sectors can take days, especially if retry passes are configured aggressively. The general guidance from professional services: if a clone has been running for more than a week without significant progress, the drive likely needs hardware-level intervention rather than continued software cloning attempts.
Imaging to a file is generally preferred for recovery purposes. The image file can be analyzed by recovery software directly, copied to multiple destinations as backup, and stored alongside the mapfile and recovery notes. Cloning directly to another physical drive can produce sector-size compatibility issues if the destination uses different sector sizes (512-byte native vs 4K native vs 512-byte emulated), and the destination drive can’t easily be backed up itself. The exception is when you specifically need a bootable replacement drive; in that case, cloning to a physical destination of the same or larger capacity makes sense. For pure recovery work, the image-file approach is more flexible and safer.
Related glossary entries
- Disk Image: the artifact produced by sector-by-sector cloning.
- Sector: the unit of storage that sector-by-sector cloning operates on.
- Data Recovery: the umbrella concept; cloning is its foundational technique.
- Bad Sectors: the primary reason standard tools fail and ddrescue succeeds.
- File Carving: signature-based recovery typically run against an image after cloning.
- Click of Death: physical failure scenario where cloning may not be possible at all.
- Firmware Corruption: scenario where hardware imagers are required over software.
Sources
- CGSecurity TestDisk documentation: DDRescue: data recovery from damaged disk (accessed May 2026)
- Technibble Forums: Sector by sector clone discussion
- EaseUS: Clone a Drive with Bad Sectors
- SevenForums: Best method/tool for cloning a failing HDD
- Data-Medics Forum: How to Clone a Hard Drive With Bad Sectors Using ddrescue
- GNU ddrescue manual / GitHub gist: Guide for using Ddrescue to recover data
- Data-Medics: same source, on the mapfile concept
- Datarecovery.com: How to Clone Hard Disks with ddrescue
- AOMEI: How to Use Ddrescue on Windows
About the Authors
Data Recovery Fix earns revenue through affiliate links on some product recommendations. This does not influence our reference content. Glossary entries are written and reviewed independently based on documented research, vendor documentation, independent testing, and recovery-engineer review. If anything on this page looks inaccurate, outdated, or worth revisiting, please reach out at contact@datarecoveryfix.com and we’ll review it promptly.
