Per ongeluk verwijderen van bestanden, geformatteerde SD-kaart en fotoherstel¶
Noodnummers verschillen per land. Deze pagina gebruikt 911, het nummer voor de Verenigde Staten en Canada. Veel andere landen gebruiken 112, 999 of een ander nummer. Zoek het nummer voor uw land.
Het besef dat je zojuist de verkeerde SD-kaart van de camera hebt geformatteerd, de Prullenbak of de Prullenbak op een externe werkschijf hebt geleegd of per ongeluk een hele partitie met onvervangbare familiefoto's hebt gewist, is een acute technische crisis. Wanneer een bestand wordt verwijderd of een opslagmedium snel wordt geformatteerd, wist het besturingssysteem zelden meteen de onbewerkte binaire gegevens in de geheugencellen. In plaats daarvan verwijdert het de mapaanwijzer van het bestandssysteem en markeert het die logische blokadressen als "vrije ruimte" die beschikbaar is om te worden overschreven. Of u 100 procent van uw gegevens herstelt of voor altijd kwijtraakt, hangt volledig af van wat er gebeurt tijdens de eerste 60 seconden na verwijdering. Elke seconde blijft de schijf geactiveerd in de lees-schrijfmodus, indexering van het besturingssysteem op de achtergrond, wisselbestanden, browsercaches en Solid State Drive (SSD) garbage collection-routines (TRIM / UNMAP) kan de onderliggende sectoren permanent op nul zetten.
Als bij het per ongeluk verwijderen of formatteren sprake is van medische telemetrie, juridisch bewijsmateriaal bij een actieve misdaad of een storing in het levensveiligheidssysteem, bel dan uw lokale alarmnummer (911 in de Verenigde Staten en Canada, 112 in de hele Europese Unie, 999 in het Verenigd Koninkrijk) of raadpleeg onze internationale gids noodnummers voordat u de hardware aanraakt. Voor alle incidenten met gegevensverlies bij consumenten, fotografen, universiteiten en ondernemingen dient u onmiddellijk alle schijfactiviteiten stop te zetten en de onderstaande forensische herstelworkflow te volgen.
Doe dit nu¶
- Trek de verwijderbare SD-kaart, CFexpress-kaart of USB-drive er onmiddellijk uit: Als u zojuist een camerageheugenkaart hebt geformatteerd of bestanden op een externe USB-drive hebt verwijderd, schakel dan onmiddellijk de aan/uit-schakelaar van de camera uit of koppel de externe USB-kabel los van de computer. Maak niet ‘één testfoto’ om te zien of de kaart werkt, en laat Windows niet toe (
chkdsk) of macOS (fsck_apfs) om de schijf te "scannen en repareren". - Als u bestanden hebt verwijderd van de interne systeemschijf van uw computer (C: drive of macOS Macintosh HD), schakel dan de stroom uit of forceer een harde uitschakeling: Sluit apps niet normaal, download geen software voor gegevensherstel naar de getroffen computer en klik niet op "Afsluiten" (waardoor gigabytes aan slaapstandbestanden, registercomponenten en sessielogboeken over uw verwijderde blokken worden geschreven). Houd de fysieke aan/uit-knop 5 tot 10 seconden ingedrukt totdat het apparaat volledig is uitgeschakeld, of koppel het netsnoer van de desktop los als het een systeem zonder batterij is.
- Schuif de fysieke schrijfbeveiligingsschakelaar op SDHC/SDXC-kaarten van volledige grootte naar de LOCK-positie: Kijk naar de linkerrand van een standaard SD-kaart van 32 millimeter bij 24 millimeter (1,26 inch bij 0,94 inch) en druk het kleine plastic lipje naar beneden richting de onderkant (weg van de gouden contactpinnen) zodat geen enkele lezer per ongeluk kan schrijven
.DS_Store,System Volume Informationof Spotlight-indexbestanden wanneer u deze later aansluit. - Begrijp de SSD TRIM-trap voordat u een interne SSD weer inschakelt: moderne NVMe- en SATA Solid State-schijven werken op hardwareniveau
TRIM(ATA) ofDeallocate(NVMe)-opdrachten binnen enkele seconden tot minuten na het verwijderen of formatteren van bestanden. Zodra de SSD-controller op de achtergrond garbagecollection op bijgesneden pagina's uitvoert, leest de raw carving-software alleen nullen (0x00). Als u de stroom uitschakelt, stopt de interne SSD-microprocessor met het voltooien van de verzameling van afval op de achtergrond. - Prepare a separate, clean secondary computer and a larger destination drive: Never install recovery tools onto the drive that lost data, and never restore recovered files back onto the same source drive during the scan. Use a second computer (or boot the affected PC from an external Ubuntu Linux Live USB flash drive) and attach a blank external hard drive with at least twice the storage capacity of the affected drive.
- Maak een onbewerkte binaire afbeelding per sector (
.imgof.dd) before running any file recovery parser: Before running PhotoRec, R-Studio, DMDE, or UFS Explorer, useddrescueor HDDSuperClone to clone every sector of the SD card or drive into a single image file on your backup drive. You can then run multiple recovery algorithms safely against the image file without ever risking further wear or accidental writes on the original media.
Danger
Nooit rennen CHKDSK /F op Windows of Schijfhulpprogramma Eerste Hulp op macOS wanneer u probeert verwijderde bestanden of een beschadigde partitietabel te herstellen. Reparatietools voor bestandssystemen zijn ontworpen om de structurele consistentie van het besturingssysteem te herstellen, niet om uw bestanden op te slaan. Ze kappen routinematig verweesde inode-ketens af, overschrijven beschadigde File Allocation Tables (FAT) en vernietigen permanent de exacte metadata-aanwijzers die professionele tools voor gegevensherstel nodig hebben om maphiërarchieën en bestandsnamen te reconstrueren.
Decision tree: choosing the right recovery strategy by storage media and file system¶
Use this forensic triage flowchart to determine whether your deleted data can be recovered via logical file-table reconstruction, raw file signature carving, or specialized chip-off analysis:
flowchart TD
A["Accidental File Deletion or Drive Format Detected"] --> B["Immediately Power Off Device or Eject Removable Media"]
B --> C{"What type of physical storage hardware is affected?"}
C -->|"Camera SD / MicroSD / CFexpress / USB Flash"| D["Engage Physical Write-Protect Switch or Use Read-Only USB Blocker"]
C -->|"External or Internal Mechanical Hard Drive (HDD)"| E["Geen TRIM-risico: hoge herstelkans als er geen nieuwe schrijfbewerkingen plaatsvinden"]
C -->|"Interne of externe SSD / NVMe / Mac / Smartphone"| F{"What File System and OS Connection Was Used?"}
F -->|"NTFS, APFS, or ext4 on Internal NVMe/SATA SSD"| G["High TRIM Risk: Boot via Linux Live USB with libata.force=noncqtrim"]
F -->|"exFAT or FAT32 over Standard USB Mass Storage"| H["Moderate/Low TRIM Risk: Many USB Bridges Do Not Pass TRIM on exFAT"]
F -->|"iOS / Android Internal Storage"| I["Hardware File-Based Encryption (FBE): Keys Destroyed on Deletion, Check Cloud/Local Backups Immediately"]
D --> J["Create Full Bitstream Clone (.img) Using GNU ddrescue onto Separate Drive"]
E --> J
G --> J
H --> J
J --> K{"Were Files Deleted Individually or Was the Drive Formatted?"}
K -->|"Individual Deletion / Quick Format (Metadata Intact)"| L["Run Logical Metadata Reconstruction (DMDE, R-Studio, UFS Explorer, TestDisk)"]
K -->|"Overwritten File Table / Camera In-Body Format"| M["Run Raw File Signature Carving + Fragmented Video Rebuilder (PhotoRec, GoPro/MP4 Repair)"]
The physics of deletion: HDD magnetic platters vs. SSD NAND flash and Camera SD cards¶
To avoid destroying recoverable data, you must understand how different storage architectures handle deletion and formatting under the hood.
1. Mechanical Hard Disk Drives (HDD) and Shingled Magnetic Recording (SMR)¶
On a traditional conventional magnetic recording (CMR) spinning hard drive, deleting a file or running a "Quick Format" takes less than two seconds because the read/write heads only modify the master directory index, such as the $MFT (Master File Table) on NTFS, the Allocation Bitmap and Catalog B-Tree on HFS+/APFS, or the File Allocation Table on FAT32/exFAT. The actual magnetic flux reversals representing your JPEGs, PDFs, and spreadsheets remain untouched on the cobalt-alloy platters until the operating system chooses to write a brand-new file over those exact Logical Block Addresses (LBAs).
However, many modern high-capacity consumer external hard drives (typically 2 terabytes to 5 terabytes in 2.5-inch portable enclosures) use Shingled Magnetic Recording (SMR) alongside an internal firmware translation layer called a Media Cache. Some modern SMR hard drives actually support the TRIM command just like an SSD. If you delete a large folder on a TRIM-enabled SMR hard drive and leave it plugged in idle for 20 minutes, the drive's internal firmware may reorganize its shingled bands and permanently zero out the unallocated sectors in the background. Unplugging the drive immediately prevents this internal housekeeping cycle.
2. Solid State Drives (SSD), NVMe, and the TRIM / Deallocate Execution Window¶
NAND flash memory inside SSDs cannot overwrite existing data directly in place. Before a NAND flash cell can accept new data, an entire flash block (typically 4 megabytes to 16 megabytes in size) must first undergo a slow electrical Program/Erase (P/E) cycle. If the SSD waited until you saved a new file to erase old blocks, write speeds would plummet.
To keep SSDs fast, modern operating systems (Windows 7 through Windows 11, macOS 10.10+, and Linux kernels with fstrim of discard) send an immediate TRIM (SATA) of Dataset Management: Deallocate (NVMe)-opdracht naar de SSD-controller op het moment dat u de Prullenbak/Prullenbak leegmaakt of een Quick Format uitvoert:
- Deterministische Read Zero na TRIM (DZAT / DRAT): Bijna alle moderne NVMe- en SATA SSD's voor consumenten dwingen deterministische nulstelling af na TRIM. De exacte milliseconde die de SSD-controller ontvangt
TRIMcommando voor een reeks sectoren, ontkoppelt de interne Flash Translation Layer (FTL) die logische adressen van de fysieke NAND-pagina's. - Immediate Zero Return: Zelfs voordat de fysieke elektrische lading uit de siliciumcellen is verwijderd, kan eventuele software (inclusief
ddrescue, PhotoRec of R-Studio) vraagt de SSD om die bijgesneden sectoren te lezen via standaard SATA- of NVMe-opdrachten, de SSD-controller onderschept het verzoek en retourneert pure hexadecimale nullen (00 00 00 00) zonder zelfs maar de fysieke NAND-chips te controleren. - Wanneer SSD-herstel nog steeds mogelijk is:
- Externe USB-behuizingen zonder UASP/TRIM pass-through: Oudere USB 3.0-bridgechips die het oudere BOT (Bulk-Only Transport)-protocol gebruiken in plaats van UASP (USB Attached SCSI Protocol) kunnen het besturingssysteem niet vertalen
TRIMopdrachten via de USB-kabel. - FAT32- en exFAT-volumes op bepaalde besturingssysteemversies: historisch gezien verzonden verschillende builds van besturingssystemen alleen automatisch realtime
TRIMopdrachten op native gejournaliseerde bestandssystemen (NTFS,APFS,ext4) en gaf niet onmiddellijk realtime uitTRIMop verwijderbaarFAT32ofexFATpartities. - Partitietabel wissen (
diskpart cleanof per ongeluk verwijderen van een partitie) zonder formatteren: het verwijderen van een partitie-item uit de GUID Partition Table (GPT) of Master Boot Record (MBR) laat soms de onderliggende sectoren niet bijsnijden totdat er een nieuw bestandssysteem bovenop wordt geformatteerd.
- Externe USB-behuizingen zonder UASP/TRIM pass-through: Oudere USB 3.0-bridgechips die het oudere BOT (Bulk-Only Transport)-protocol gebruiken in plaats van UASP (USB Attached SCSI Protocol) kunnen het besturingssysteem niet vertalen
3. Camera-in-body-formattering en Sony / Canon / Nikon SD_ERASE Val¶
Fotografen en videografen gaan er vaak van uit dat het formatteren van een SD-, microSD- of CFexpress-kaart in een digitale camera identiek is aan een "Quick Format" op een desktopcomputer. Hoewel dat tien jaar geleden waar was, gedragen moderne spiegelloze camera's zich heel anders, afhankelijk van de fabrikant:
| Cameramerk en mediatype | Wat er gebeurt tijdens het in-camera "formatteren" | Impact op doe-het-zelfsoftwareherstel | Onmiddellijke actie vereist |
|---|---|---|---|
| Canon (EOS R-serie, DSLR) standaardformaat | Overschrijft alleen de FAT/exFAT-hoofdmap en toewijzingstabellen (0x00 in kopsectoren). Laat onbewerkte beeld-/videoclusters intact. |
Zeer groot succes (95%+): Raw carving en gefragmenteerde MP4-rebuilders kunnen CR2/CR3-foto's en MOV/MP4-video extraheren. | Verwijder de kaart onmiddellijk en vergrendel de schrijfschakelaar. Selecteer NIET "Low Level Format". |
| Canon "Low Level Format" (selectievakje aangevinkt) | Issues hardware ERASE (CMD38)-opdracht naar de SD-kaartcontroller, waarbij alle flashblokken op de hele kaart worden verwijderd. |
Near Zero via Card Reader: Card returns 0x00 of 0xFF across all sectors. Requires lab monolithic NAND pinout dump if FTL only unmapped blocks. |
If realized midway through the progress bar, pop the battery door or pull the card immediately to save the un-erased percentage. |
| Sony Alpha (a7 IV, a7S III, a9, FX3, FX6) Full Format | Sends physical SD_ERASE / DISCARD command (CMD32/CMD33/CMD38) to SDXC and CFexpress Type A/B controller during standard format. |
Zero via Standard Software: Standard recovery tools scan the entire card in 30 seconds and find 0 files because every sector reads 0x00 of 0xFF. |
Stop immediately. Do not write to the card. Only specialized forensic labs capable of reading raw NAND bypassing the controller (and only on certain controllers) have any chance. |
| Nikon (Z series, DSLR) / Fujifilm / Panasonic Lumix | Typically clears file system structures on SD cards; however, CFexpress Type B cards use PCIe NVMe protocols and often execute NVMe Format NVM / Deallocate commands. |
Hoog op SDXC; Laag op CFexpress: SDXC-kaarten herstellen doorgaans goed; CFexpress Type B-kaarten vallen vaak weg via de garbage collection van de NVMe-controller. | Remove card immediately. Image with ddrescue and inspect the hex view (0x00 vs random high-entropy data) to verify if blocks were deallocated. |
| DJI Drones / GoPro Action Cameras / Insta360 | Uses exFAT/FAT32 and often records dual streams (.MP4 + .LRV low-res preview + .THM thumbnail) in interleaved data chunks. |
High for Photos; Specialized Tool Needed for Video: Standard carvers (PhotoRec) produce unplayable video files because high-bitrate MP4 streams are split across non-contiguous clusters interlaced with .LRV data. |
Image the microSD card first, then use a cluster-aware fragmented video reconstructor (recover_mp4, AeroQuartet Treasured, or SanDisk RescuePRO Deluxe). |
Warning
How can you tell in 10 seconds if your formatted SD card or SSD was hit by hardware TRIM of SD_ERASE? Open your disk image (or read-only card) in a free hexadecimal viewer (such as HxD on Windows, 0xED op macOS, of hexdump -C op Linux) en blader langs de eerste 32 megabytes (0,03 gigabytes) naar het midden van de schijf. Als je duizenden regels met gevarieerde, willekeurig uitziende hexadecimale tekens ziet (A4 7F 2C 91 E0..), zijn uw foto's en video's nog steeds fysiek aanwezig en kunnen ze voor 100 procent worden hersteld. Als het hele midden van de schijf doorgetrokken lijnen is 00 00 00 00 of FF FF FF FF, the flash controller has unmapped the sectors via TRIM/ERASE, and no commercial software on earth can read them through a standard USB reader.
Phase 1: Immediate OS containment and blocking automatic writes¶
Before you try to recover files from an internal drive or attach an external drive to a computer, you must neutralize the operating system mechanisms that silently overwrite deleted space.
1. Recovering from an Internal Windows Drive (C: Drive)¶
If you deleted an important folder from your Windows Desktop, Documents, or Downloads folder and emptied the Recycle Bin:
- Do NOT keep using Windows on that drive: Even leaving Windows sitting idle at the Desktop allows
SearchIndexer.exe, Windows Defender background scans, Chrome/Edge cache updates, Volume Shadow Copy rotation, and the Windows Pagefile (pagefile.sys) to write hundreds of megabytes per minute directly over your newly freed clusters. - If you cannot power off immediately (for example, on a remote workstation with no physical access), disable
TRIMinstantly via Administrator Command Prompt:- Press
Win + X, click Terminal (Admin) or Command Prompt (Admin), and execute: - This stops Windows from sending any further
TRIMnotifications for NTFS and ReFS volumes, though it cannot undoTRIMcommands sent seconds earlier.
- Press
- Check if a Volume Shadow Copy (
Previous Versions) already exists before shutting down (takes 15 seconds):- Right-click the parent folder that held your deleted files, click Properties -> Previous Versions.
- Or run
vssadmin list shadowsin an Administrator Command Prompt. If a shadow snapshot exists from earlier today or yesterday, you can mount that shadow copy read-only (mklink /d C:\ShadowRestore \\?\GLOBALROOT\Device\HarddiskVolumeShadowCopy1\) and copy your intact files directly to an external USB thumb drive.
- If no Shadow Copy exists, shut down hard and boot from a Linux Live USB: Create an Ubuntu or SystemRescue USB flash drive on a different computer, boot the affected PC from that USB drive in Try Ubuntu (Live RAM mode) without mounting the internal drive rw, and image or extract the files from outside Windows.
2. Recovering from a macOS System Drive (Apple Silicon M1/M2/M3/M4 & T2 Macs)¶
Moderne Apple-computers met macOS op APFS (Apple File System) bieden twee strikte architecturale hindernissen:
- Agressieve APFS TRIM: macOS verzendt
TRIMcommando's onmiddellijk na het legen van de prullenmand op interne Apple SSD's. - Hardware FileVault / Secure Enclave Encryption: Op alle Macs met een Apple T2-chip of Apple Silicon (M1, M2, M3, M4) wordt de interne SSD in rust standaard hardware-gecodeerd met behulp van sleutels die zijn gekoppeld aan de Secure Enclave, zelfs als FileVault is uitgeschakeld in Systeeminstellingen.
- Onmiddellijke controle 1: momentopnamen van lokale tijdmachines (
tmutil): Even if your external Time Machine backup drive was unplugged at the time of deletion, macOS automatically creates hidden hourly APFS Local Snapshots on the internal SSD if Time Machine is configured. Open Terminal immediately and run: If you see snapshots listed (such ascom.apple.TimeMachine.2026-10-31-091522.local), open the folder where the file lived and launch the Time Machine app from Applications to restore the file in seconds. - Immediate Check 2: Cloud Sync Trash Bins (iCloud Drive, OneDrive, Dropbox, Google Drive): Because macOS Desktop and Documents folders are frequently synced to iCloud Drive, deleting a file from your Mac Desktop deletes it via iCloud sync rather than just locally. Open a browser on your phone or another PC, log into
icloud.com-> Schijf -> Onlangs verwijderd (rechtsonder), waarbij verwijderde bestanden 30 dagen bewaard blijven, volledig onaangetast door de lokale SSDTRIM.
- Onmiddellijke controle 1: momentopnamen van lokale tijdmachines (
3. Blocking macOS and Windows from Polluting a Plugged-in SD Card or External Drive¶
When you plug a camera SD card or external USB drive into a computer to recover files, the host operating system immediately tries to write hidden metadata files onto the root of the drive (.DS_Store, .Spotlight-V100, .fseventsd, .Trashes on macOS; System Volume Information en $Recycle.Bin on Windows). Those tiny writes land right at the beginning of the free space bitmap, often corrupting the exact directory headers you are trying to recover.
- Op Linux (veiligste forensische methode): Linux schrijft niet automatisch naar verborgen indexmappen als u automatisch koppelen uitschakelt of het blokapparaat strikt alleen-lezen aankoppelt (
ro,noload). - Op Windows (schakel alleen-lezen schijfkenmerk in via DiskPart VOORDAT u de schijf plaatst, of gebruik Registry WriteBlocker):
- Open
regedit.exeas Administrator, navigate toHKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\StorageDevicePolicies(create theStorageDevicePolicieskey if it does not exist), and create aDWORD (32-bit)value namedWriteProtectset to1. Plug in your USB card reader afterward, and Windows will treat all removable USB storage as hardware write-protected.
- Open
- On macOS (Mount via Disk Arbitrator): Download and launch the open-source utility Disk Arbitrator before plugging in your SD card reader or external drive. Set Disk Arbitrator to Block Mounts or Mount Read-Only, so macOS cannot write
.DS_Storeor Spotlight indexes onto the damaged partition.
Phase 2: Creating a forensic sector-by-sector clone (ddrescue)¶
Never run file recovery scans directly on a failing hard drive, a worn-out microSD card, or the sole copy of a formatted partition. Creating a raw binary image file (.img of .dd) guarantees that you have a frozen, bit-for-bit snapshot of every sector as it existed the moment you unplugged the drive.
Step-by-Step Cloning with GNU ddrescue (Linux / macOS) or HDDSuperClone¶
- Identify the exact device identifier of your source card or drive:
- On Linux, run
lsblk -o NAME,SIZE,MODEL,RO,FSTYPE,MOUNTPOINTbefore and after plugging in the card reader. Suppose your 64 gigabyte (59.6 gibibyte) camera SD card appears as/dev/sdc(make sure it is not mounted; if mounted, runsudo umount /dev/sdc1). - On macOS, run
diskutil listto find the disk number (for example,/dev/disk4), then unmount its volumes without ejecting the hardware:diskutil unmountDisk /dev/disk4.
- On Linux, run
- Mount your large destination storage drive: Suppose your external 2 terabyte backup drive is mounted at
/mnt/backup(of/Volumes/BackupDriveon macOS). Verify it has enough free space to hold the entire raw capacity of the source drive (a 64 gigabyte SD card produces a 64 gigabyte.imgfile, even if only 10 gigabytes of photos were on it). - Execute
ddrescuewith a mapfile (log file):-dmaakt gebruik van directe schijftoegang (waarbij de kernelpaginacache van het besturingssysteem wordt omzeild voor nauwkeurige sectorlezingen; bij macOS-gebruik/dev/rdisk4in plaats van-d).-r3tellsddrescueto copy all healthy sectors across the entire drive on the first fast pass, skip over any slow or damaged flash blocks immediately so the card does not overheat or lock up, and then retry bad sectors up to 3 times at the end.sdcard_rescue.mapsaves your exact progress every few seconds. If the USB reader disconnects or the power goes out, running the exact same command resumes seamlessly from where it stopped without re-reading already rescued sectors.
- Make a working copy or mount the
.imgfile read-only: Oncesdcard_raw_clone.imgfinishes at100.00% rescued, eject your physical SD card and store it in a safe drawer. You will perform 100 percent of your recovery work onsdcard_raw_clone.img.
Tip
If you are working on Windows and cannot boot a Linux Live USB, you can create a sector-by-sector raw image file (sdcard_raw_clone.img of .dsk) for free using the built-in imaging tool inside DMDE (DM Disk Editor and Data Recovery Software) (Tools -> Copy Sectors -> Source: Physical Drive -> Destination: File), R-Studio (Create Image in the free demo version), or USB Image Tool. Always choose a plain Raw / Byte-to-Byte Image (.img / .bin) in plaats van een eigen gecomprimeerd back-upformaat, zodat elk herstelprogramma het kan openen.
Phase 3: Executing file recovery (Logical Metadata Reconstruction vs. Raw Carving)¶
Zodra je een kluis hebt .img -bestand (of een door hardware schrijfgeblokkeerde schijf), zijn er twee totaal verschillende technische methoden om uw verwijderde gegevens te extraheren. Probeer altijd eerst Methode A (Reconstructie van logisch bestandssysteem) voordat u terugkeert naar Methode B (Raw Signature Carving).
| Feature | Method A: Logical File System Reconstruction | Method B: Raw Signature Carving (Header/Footer Scan) |
|---|---|---|
| How It Works | Parses remnant file system structures ($MFT records on NTFS, FAT/exFAT directory entries, APFS B-trees, ext4 journal/inodes) to locate deleted pointers. |
Ignores the file system completely. Reads every 512-byte or 4096-byte sector looking for magic byte headers (e.g., FF D8 FF for JPEG, 89 50 4E 47 voor PNG, %PDF for PDF). |
| Folder Structure & Filenames | Preserved: Restores original folder trees (/DCIM/100CANON/), original filenames (IMG_4821.CR3), and creation timestamps. |
Lost: Produces thousands of generic numbered files (f0012842.jpg, f0019200.pdf) in flat recovery directories (recup_dir.1/), though EXIF dates can be parsed later to rename photos. |
| Handling Fragmented Files | Excellent: If cluster runs remain in the $MFT record or FAT table, reconstructs files split across non-contiguous disk chunks. |
Poor for Fragmented Video: Assumes every file is stored in one continuous block from header to footer. Breaks down on fragmented MP4/MOV video or heavily fragmented drives. |
| Best Tools | DMDE, R-Studio, UFS Explorer, ReclaiMe, TestDisk (for whole lost partitions). | PhotoRec (100% Free/Open-Source), Disk Drill / SanDisk RescuePRO Deluxe (for fragmented GoPro/drone video). |
Step-by-Step 1: Restoring a Deleted Partition or Corrupted Boot Sector with TestDisk¶
Als uw externe schijf of SD-kaart plotseling vraagt *"U moet de schijf in station E formatteren: voordat u deze kunt gebruiken"* of wordt weergegeven als RAW / Niet-toegewezen in Schijfbeheer nadat u deze hebt losgekoppeld zonder veilig uit te werpen, zijn uw bestanden helemaal niet verwijderd. In plaats daarvan worden de Master Boot Record (MBR), GUID Partition Table (GPT) of Boot Sector (BPB) was corrupted.
- Voer TestDisk uit tegen uw gekloonde afbeeldingsbestand:
- Selecteer Doorgaan -> bevestig het type partitietabel (
Intel/PCfor MBR SD cards under 2 terabytes, orEFI GPTfor modern large drives). - Select Analyse -> Quick Search.
- TestDisk will scan for backup partition headers (such as the automatic backup NTFS boot sector stored at the very last sector of an NTFS volume, or the backup FAT32 boot sector at sector 6).
- Highlight the discovered partition and press
P(List Files). If you immediately see all your folders and files listed intact inside the terminal window:- Doe niet eens de moeite om de partitietabel te herschrijven als u alleen de bestanden wilt. Druk gewoon op
Cop de gewenste mappen en kopieer ze rechtstreeks naar uw gezonde bestemmingsstation met 100 procent originele bestandsnamen en mapstructuren.
- Doe niet eens de moeite om de partitietabel te herschrijven als u alleen de bestanden wilt. Druk gewoon op
Stap voor stap 2: Scannen van logische metadata met DMDE, R-Studio of UFS Explorer¶
Wanneer bestanden werden verwijderd via Shift + Delete, geleegd uit de Prullenbak of gewist via een standaard Quick Format:
- Open uw
.imgfile inside DMDE (free edition recovers up to 4,000 files per directory action; full license is inexpensive), R-Studio, or UFS Explorer Standard Recovery. - Check the Existing Virtual File System Tree First:
- On NTFS drives, each file has a 1,024-byte (1 kilobyte) record in the Master File Table (
$MFT). Even when a file is deleted, its$MFTslot remains marked with an inactive flag (0x00in plaats van0x01) containing the exact filename, parent directory ID, and exact starting cluster and length runs, until a new file reuses that$MFTslot. Furthermore, files smaller than ~700 bytes (such as brief text notes, crypto keys, or small scripts) are stored resident entirely inside the$MFTrecord itself and rarely get overwritten quickly. - Look in the
$RootorDeleted / Foundvirtual folder generated within the first 5 seconds of opening the partition. If your files appear with a redxor trash icon and show a healthy size, select them and click Recover to your separate destination drive immediately.
- On NTFS drives, each file has a 1,024-byte (1 kilobyte) record in the Master File Table (
- Run a Full Volume Scan if the Directory Header Was Overwritten:
- If a Quick Format overwrote the root directory or the first few megabytes of the
$MFT, run a Full Volume Scan. The software will scan the entire image for surviving subdirectory index nodes (INDXbuffers on NTFS, subdirectory cluster chains on FAT32/exFAT, or older transaction checkpoints on APFS/ext4) and combine logical metadata with raw file signature detection.
- If a Quick Format overwrote the root directory or the first few megabytes of the
Step-by-Step 3: Raw File Carving with PhotoRec (When Metadata Is Completely Destroyed)¶
When the File Allocation Table (FAT) or $MFT has been completely zeroed out by a format, logical directory pointers are gone, leaving only the raw file contents sitting in unallocated data clusters. PhotoRec (bundled alongside TestDisk, completely free, open-source, and available for Windows, macOS, and Linux) excels at carving over 480 file formats (including Canon .CR2/.CR3, Sony .ARW, Nikon .NEF, Adobe .DNG/.PSD, .JPG, .PNG, .PDF, .DOCX/.XLSX zip containers, and .SQLITE databases):
- Launch PhotoRec against your disk image:
- Selecteer de doelpartitie (of
Whole diskif the partition table was wiped). - Before starting, go to
[File Opt]at the bottom of the screen:- Press
som alle 480 bestandstypen te deselecteren als u alleen om specifieke bestanden geeft (controleer bijvoorbeeld alleenjpg,cr2/cr3,tifvoor onbewerkte foto's,mov/mp4, Enzip/docx), wat het herstel drastisch versnelt en vals-positieve afvalfragmenten voorkomt.
- Press
- Selecteer
[Options]-> behoudenKeep corrupted files : Notenzij beschadigde videostreams worden hersteld. - Selecteer
[Search], kies bestandssysteemtype[Other](voor FAT/exFAT/NTFS/HFS+) en selecteer[Free](als u alleen bestanden op een actieve partitie hebt verwijderd) of[Whole](als de partitie geformatteerd was). - Kies een doelmap op uw aparte grote back-upschijf en druk op
Com te beginnen met snijden. - Post-Recovery Sorting for PhotoRec Output: Because PhotoRec saves files as
f123456.jpgover tientallenrecup_dirfolders, you can automatically reorganize all recovered photos into cleanYYYY/MM-Month/folders with their exact camera timestamp filenames using the free command-line tool ExifTool:
Specialized recovery: fragmented camera MP4/MOV videos (GoPro, DJI Drones, Sony, Canon)¶
One of the most frequent frustrations after running PhotoRec or standard file recovery software on a formatted camera card is discovering that 100 percent of the recovered .JPG en .RAW photos open perfectly, but every single recovered .MP4 of .MOV video file refuses to play (0:00 duration or black screen).
Why Standard Recovery Software Breaks Modern Camera Videos¶
- Interleaved Stream Recording: Modern action cameras (GoPro Hero series, DJI Air/Mavic/Mini drones, Insta360) and cinema mirrorless cameras do not write a single
.MP4file sequentially from start to finish. While recording 4K or 5.3K video, the camera simultaneously writes a high-resolution.MP4stream, a low-resolution preview.LRVstream, an audio buffer, and telemetry metadata into alternating clusters on the exFAT/FAT32 card (for example: 4 megabytes of high-res video, followed by 512 kilobytes of.LRVpreview, followed by 4 megabytes of high-res video). - Missing
moovAtom in Unfinalized Recordings: If your drone crashed into water, your camera battery died mid-recording, or the SD card disconnected before you pressed the Stop Record button, the camera never wrote themoovatom (the master index table written at the very end of an MP4/MOV file that tells media players where every video frame and audio chunk sits).
How to Rebuild Unplayable or Fragmented Camera Videos¶
- Case A: Unfinalized Video After Battery Loss or Crash (File Exists on Card, Shows Multi-GB Size, Won't Play):
- The clusters are intact in the file system, only the
moovindex header is missing. - Use the free, open-source tool
untrunc(specifically theanthwlock/untruncfork) orrecover_mp4(slydiman). Provideuntruncwith one healthy, playable reference.MP4recorded on that exact same camera with the exact same resolution and framerate settings, alongside your broken.MP4: untruncreads the codec parameters (avcC/hvcCand audio track layouts) from the working reference video, scans the raw H.264/H.265/HEVC NAL units in your damaged file, and synthesizes a brand-newmoovatom in seconds.
- The clusters are intact in the file system, only the
- Case B: Formatted SD Card with Interleaved / Fragmented Video (GoPro, DJI, Sony, Canon):
- Omdat de FAT/exFAT-clusterkaart tijdens het formatteren is gewist, pakt een standaardcarver de
ftyp/mdatheader van uw 4K-video en kopieert vervolgens blindelings de.LRVbekijk voorbeeldclusters en miniatuurclusters in het midden van uw videobestand, waardoor elke seconde aan beeldmateriaal wordt beschadigd. - In plaats van standaard carvers, scant u uw
sdcard_raw_clone.imgmet behulp van een fragmentatiebewuste videoreconstructor die cameraspecifieke clustertoewijzingsfrequenties herkent, zoals SanDisk RescuePRO Deluxe (die specifieke GoPro/drone gefragmenteerde video-assemblage-algoritmen bevat), Klennet Carver of Disk Drill 5+ (die een speciale GoPro/DJI-reconstructor voor gefragmenteerde videohandtekeningen bevat).
- Omdat de FAT/exFAT-clusterkaart tijdens het formatteren is gewist, pakt een standaardcarver de
Fotoverwijdering op smartphone: realiteit van iOS (iPhone) en Android-hardware-encryptie¶
Een veel voorkomende en gevaarlijke misvatting is dat je een moderne iPhone of Android-smartphone via USB op een laptop kunt aansluiten en traditionele schijfcarvingsoftware (zoals Recuva of PhotoRec) op de interne opslag van de telefoon kunt draaien.
Waarom traditionele sectorcarving moderne telefoons niet kan lezen¶
Elke iPhone sinds de iPhone 3GS (en alle huidige iOS-apparaten) maakt gebruik van Gegevensbescherming (bestandsgebaseerde codering), mogelijk gemaakt door een speciale hardware-AES-crypto-engine tussen de flashopslag en het hoofdsysteemgeheugen. Op dezelfde manier maakt elk Android-apparaat dat wordt geleverd sinds Android 7.0+ (en verplicht sinds Android 10) gebruik van File-Based Encryption (FBE), ondersteund door de hardware Keystore/Titan M/Knox-chip.
On both platforms, every single individual photo and file on the internal storage is encrypted with its own unique per-file cryptographic key. When a file is permanently purged from the phone's file system, the phone does not even need to erase the multi-megabyte photo blocks; it immediately destroys the 256-bit per-file encryption key in the metadata table. Without that key, the raw NAND blocks contain cryptographically unbreakable random noise. Even top-tier government forensic labs cannot "carve" permanently deleted photos from the internal flash of a modern iPhone or Android once the per-file key is wiped.
The Actual Recovery Paths for Deleted Smartphone Photos¶
Because hardware encryption blocks raw carving, recovering deleted photos from an iPhone or Android relies on recovering copies before retention timers expire or extracting cached thumbnail databases:
- Check the On-Device "Recently Deleted" Album Immediately (30-Day Window):
- iOS (iPhone / iPad): Open Foto's -> scrol omlaag naar Hulpprogramma's -> tik op Onlangs verwijderd (vereist Face ID / Touch ID / Toegangscode). Foto's blijven hier 30 dagen staan voordat de sleutel definitief wordt vernietigd.
- Android (Google Foto's / Samsung Gallery): Open Google Foto's -> Bibliotheek/collecties -> Prullenbak/prullenbak (bewaard gedurende 60 dagen indien er een back-up van wordt gemaakt, 30 dagen indien alleen op het apparaat). Controleer ook Samsung Gallery -> Menu (drie regels) -> Prullenbak (bewaard gedurende 30 dagen) en open de app Files by Google of Mijn bestanden -> Prullenbak, die een aparte prullenbakmap voor 30 dagen bijhoudt.
- Als u foto's hebt verwijderd van "Recent verwijderd" op de iPhone, bel dan Apple Support voor een noodherstel via iCloud aan de serverzijde:
- Veel gebruikers realiseren zich niet dat zelfs nadat u handmatig op "Verwijderen van alle apparaten" / "Onlangs verwijderd" in iCloud-foto's klikt, de backend-servers van Apple een voorlopig verwijderde serverherstelbuffer behouden voor een korte periode (doorgaans tot 7 tot 14 dagen na permanente verwijdering).
- Neem onmiddellijk contact op met Apple Support per telefoon of chat, vraag om een Senior Advisor te spreken en vraag hem of haar een iCloud Fotobibliotheek Server-Side Herstel te activeren voor uw Apple Account. Ze kunnen vaak een serverschakelaar omzetten die onlangs verwijderde iCloud-foto's binnen 15 minuten weer in uw album dumpt.
- Restore from an Older Unsynced Device or Encrypted Local Backup:
- Airplane Mode Trick on Secondary iPad / Mac: If your iPhone synced a deletion to iCloud, grab your iPad or MacBook before it connects to Wi-Fi (turn off your home Wi-Fi router unplugging the power cord first if the iPad is asleep on your desk). Power on the iPad in total radio isolation, copy the still-present photos via USB cable or AirDrop to another device before the iPad receives the iCloud deletion push command.
- Check iCloud Backup vs. iCloud Photos: If you had iCloud Photos turned OFF (
Settings -> [Your Name] -> iCloud -> Photos -> Off), your Camera Roll is included inside your nightly iCloud Device Backup. You can wipe an old spare iPhone (or temporarily back up and reset your current iPhone) and restore the nightly iCloud Backup from before the moment you deleted the photo. - Check Local Finder / iTunes Backups on Your PC or Mac: Check
~/Library/Application Support/MobileSync/Backup/on macOS or%APPDATA%\Apple Computer\MobileSync\Backup\on Windows. You can browse and extract photos from old local backups without overwriting your phone using iMazing or iBackup Viewer.
- Check Messaging App Local Caches (WhatsApp, iMessage, Telegram, Signal):
- Did you ever text the deleted photo or video to a spouse, friend, or family group chat? Messaging apps store independent copies of media inside their own application sandboxes (
Media/WhatsApp Images/Senton Android, or inside chat attachments in iMessage). Even if you delete a photo from your main Camera Roll and empty the Trash, the copy inside your WhatsAppSentfolder or iMessage thread history remains completely untouched.
- Did you ever text the deleted photo or video to a spouse, friend, or family group chat? Messaging apps store independent copies of media inside their own application sandboxes (
Danger
Beware of deceptive "iPhone / Android Data Recovery" desktop software advertised at the top of search engines (programs claiming they can "recover permanently deleted iPhone photos and texts without any backup"). Because of iOS and Android File-Based Encryption (FBE), these apps can only read existing unencrypted SQLite thumbnail caches or extract data from an existing iTunes backup on your computer. Worse, many require you to unlock and grant full USB Trust permissions on your phone while running background scripts that write temporary logs onto your phone's storage. Never pay $60 to $100 for mobile recovery software before verifying what it can actually see in a free preview.
Cloud drive and enterprise accidental deletion recovery (Google Drive, OneDrive, Dropbox)¶
When an entire shared folder disappears or is overwritten on a cloud drive (or when ransomware or a syncing glitch deletes local files and syncs the deletion to the cloud), local disk recovery is often unnecessary because enterprise and consumer cloud platforms maintain multi-tier version histories:
- Microsoft OneDrive & SharePoint Online:
- First-Stage Recycle Bin (
onedrive.live.com): Retains deleted files for 30 days on personal accounts and 93 days on Work/School accounts. - Second-Stage Site Collection Recycle Bin (Work/School): Even if an employee or hacker empties the main OneDrive Recycle Bin, click the link at the bottom of the Recycle Bin page labeled "Second-stage recycle bin", where purged files remain recoverable for the remainder of the 93-day window.
- Restore Your OneDrive (Point-in-Time Rollback): Microsoft 365 subscribers can click Settings (gear icon) -> Options -> Restore your OneDrive, which uses a visual histogram slider to roll every single file, rename, and deletion across the entire cloud drive back to any exact minute within the last 30 days.
- First-Stage Recycle Bin (
- Google Drive & Google Workspace:
- Google Drive Trash (
drive.google.com/drive/trash): Retains deleted files for 30 days. - Herstel na prullenbak van Google Workspace-beheerder (respijtperiode van 25 dagen): Zelfs nadat een gebruiker op "Voor altijd verwijderen" heeft geklikt en de Google Drive-prullenbak heeft geleegd, kan een Google Workspace-beheerder (of een individuele gebruiker die contact opneemt met Google Drive-ondersteuning via persoonlijke Google One-accounts) de Google-beheerdersconsole openen (
admin.google.com) -> Directory -> Gebruikers -> [Selecteer gebruiker] -> Meer opties -> Gegevens herstellen en herstel permanent verwijderde Google Drive-bestanden en Gmail-berichten tot 25 extra dagen nadat de prullenbak is geleegd.
- Google Drive Trash (
- Dropbox:
- Verwijderde bestanden (
dropbox.com/deleted_files): Bewaart verwijderde bestanden en mappen gedurende 30 dagen bij Basic/Plus/Family-abonnementen, en 180 dagen tot 1 jaar bij Professional/Business-abonnementen. - Dropbox Terugspoelen (
dropbox.com/rewind): Maakt het mogelijk een hele map of het hele account terug te draaien om massale verwijderingen, onbedoelde slepen en neerzetten of coderingsgebeurtenissen ongedaan te maken.
- Verwijderde bestanden (
Veelgestelde vragen¶
Can I recover files if I accidentally executed `rm -rf` on a Linux ext4 or XFS server?
If you ran `rm -rf` on an `ext4` or `XFS` partition, your very first command within 2 seconds must be to remount that partition strictly read-only (`sudo mount -o remount,ro /dev/sda1` or `sudo lsof | grep deleted` before closing running processes). First, check if any running application still holds an open file descriptor to the deleted file: run `sudo lsof +L1`; if a process still has the deleted file open in memory, you can copy it intact right out of `/proc/
What is the difference between a Quick Format and a Full Format in Windows, Mac, and Linux?
A **Quick Format** only writes a brand-new, empty file system index (such as a blank `$MFT` or FAT table) taking less than 5 percent of the drive's sectors and finishes in a few seconds; on non-TRIM mechanical hard drives and many standard camera SD cards, 95 to 100 percent of the underlying files remain recoverable. A **Full Format** (unchecking "Quick Format" in Windows since Windows Vista through Windows 11, or selecting security erase level 2+ in macOS Disk Utility) physically writes hexadecimal zeros (`0x00`) across every single sector from the start of the partition to the end (and sends hardware `TRIM`/`Deallocate` on SSDs). Once a true Full Format finishes 100 percent on any modern drive, the data is permanently overwritten and cannot be recovered by any software or laboratory.
Why did my recovered JPEG photos or Word documents open with half the picture grayed out or scrambled text?
When a recovered JPEG displays the top portion of the image clearly and the bottom half is solid gray, shifted colors, or a piece of a completely different photo, the file was **fragmented** on the drive or partially overwritten before you powered it off. If you used a raw signature carver like PhotoRec, it assumed the entire JPEG occupied consecutive clusters from header (`FF D8`) to footer (`FF D9`), when in reality the middle clusters belonged to another file. First, retry the recovery on your `.img` file using a metadata-aware tool (**DMDE**, **R-Studio**, or **UFS Explorer**) to see if a surviving directory entry still holds the real cluster fragmentation map. If the header or quantization tables are slightly damaged, tools like **JPEG-Repair Toolkit** can sometimes realign shifted MCU blocks, though overwritten sectors cannot be recreated.
My SD card or USB flash drive shows "0 Bytes / No Media" in Disk Management or does not light up at all. Can software fix it?
No. If an SD card, microSD card, or USB flash drive shows `0 MB` physical capacity in Windows Disk Management (`diskmgmt.msc`) or Linux `lsblk` / `dmesg`, the card has suffered an **electrical or firmware controller failure**, not an accidental deletion. No recovery software can scan a device whose hardware controller refuses to report its LBA capacity to the computer. Unplug it immediately; leaving a failed flash controller powered on can burn out the internal voltage lines on a monolithic microSD chip. You must send the card to a specialized **Monolithic Flash / Chip-Off Data Recovery Lab** where technicians sand down the epoxy coating under a microscope, solder ultra-fine micro-wires directly to the internal NAND flash pads (bypassing the dead controller), dump the raw NAND pages, and reconstruct the proprietary ECC and XOR scrambling algorithms.
If I accidentally started installing Windows or macOS onto the wrong backup drive and canceled it at 10 percent, can I get my files back?
Yes, a large portion of your data is often still recoverable if you stopped the OS installer early and the backup drive is a mechanical Hard Disk Drive (HDD). When an OS installer begins partitioning and copying an `install.wim` or base system image, it overwrites the partition table and the first 5 to 20 gigabytes at the start of the drive. If your backup drive is a 1 terabyte to 4 terabyte HDD containing 800 gigabytes of family archives, the remaining 780 gigabytes sitting in the middle and upper Logical Block Addresses were never touched by the aborted installation. Furthermore, NTFS often places a backup copy of directory structures and files deep into the drive. Image the drive immediately and run a full scan in **R-Studio**, **UFS Explorer**, or **DMDE** to reconstruct the upper-sector directory trees and carve remaining files.
Is it ever safe to put a clicking or unrecognized hard drive in the freezer?
**Never put a hard drive in the freezer.** The "freezer trick" is an outdated myth from the 1990s that permanently destroys modern high-density hard drives. Modern hard drive read/write heads fly on an air bearing just 1 to 3 nanometers (less than 0.0000001 inches) above platters spinning at 5,400 to 7,200 RPM. Placing a drive in a freezer causes microscopic water vapor inside the drive enclosure to condense into solid ice crystals directly on the magnetic platters. The instant you plug the cold drive in and the platters spin up, the read/write heads slam into those frost crystals at 120 kilometers per hour (75 miles per hour), causing a catastrophic head crash that scrapes the magnetic coating into metallic dust and makes cleanroom recovery impossible. For physical drive failures, see our guide on [hard drive failure and data recovery](hard-drive-failure-and-data-recovery.md).
Bronnen gecontroleerd¶
- National Institute of Standards and Technology (NIST, United States): Special Publication 800-88 Revision 1, Guidelines for Media Sanitization (ATA TRIM, NVMe Deallocate, and NAND Flash Translation Layer behavior) and Computer Forensics Tool Testing (CFTT) Program Disk Imaging Specifications (
csrc.nist.gov). - Cybersecurity and Infrastructure Security Agency (CISA, Verenigde Staten): richtlijnen voor gegevensback-up, forensische bewaring en incidentafhandeling (
cisa.gov). - GNU Project / Antonio Diaz Diaz (Internationaal): Officiële GNU ddrescue-handleiding: Data Recovery Tool en Block Device Mapfile-algoritmen (
gnu.org/software/ddrescue). - CGSecurity / Christophe Grenier (Internationaal): TestDisk & PhotoRec Officiële documentatie: Partitieherstel en handtekeningen voor bestandscarving (
cgsecurity.org). - Apple Platform Security (United States): FileVault, Data Protection Classes, Per-File Encryption Keys, and APFS Trim Architecture on Apple Silicon and T2 Systems (
support.apple.com/guide/security). - Android Open Source Project (AOSP, internationaal): File-Based Encryption (FBE) en metadata-encryptiearchitectuur (
source.android.com/docs/security/features/encryption). - SD Association (International): SD Specifications Part 1: Physical Layer Simplified Specification (Erase Commands CMD32, CMD33, CMD38 and Write-Protect Mechanical Switch) (
sdcard.org).