TestDisk

From Gentoo Wiki
Jump to:navigation Jump to:search
This article is a stub. Please help out by expanding it - how to get started.
Resources

TestDisk is a free and open source, cross platform data recovery suite. TestDisk was written by Christophe Grenier in C and is capable of recovering files and partitions on FAT12, FAT16, FAT32, NTFS, and ext2 filesystems. The project continues to be actively maintained by Grenier.

Installation

USE flags

USE flags for app-admin/testdisk Checks and undeletes partitions + PhotoRec, signature based recovery tool

+sudo Enable sudo helper integration
ewf Include ewf library
gui Enable support for a graphical user interface
jpeg Add JPEG image support
ntfs Include the ability to read NTFS filesystems
reiserfs Include reiserfs reading ability
static !!do not set this during bootstrap!! Causes binaries to be statically linked instead of dynamically
zlib Add support for zlib compression

Emerge

Install TestDisk:

root #emerge --ask app-admin/testdisk

Usage

Start TestDisk:

user $testdisk

TestDisk can work with raw disks created with dd:

user $testdisk rawdisk.dd

PhotoRec

PhotoRec is a signature based recovery tool that is installed alongside TestDisk. PhotoRec scans partitions for file header information in order to find lost or deleted files. Since file header information is queried, PhotoRec can work on a variety of file systems and is capable of finding over 400 types of files. Files found by PhotoRec do not have their original file name; recovered data is grouped into folders and labeled with a file extension matching the header information (ASCII files are labeled

  • .txt, JPEG files named
  • .jpeg, PNG files named
  • .png, etc.). In order to find the specific file, the content of each file must be searched.

Start PhotoRec:

user $photorec

See also

  • Dd — a utility used to copy raw data from a source into sink, where source and sink can be a block device, file, or piped input/output.
  • Ddrescue — a tool provided by GNU to retrieve data from failing (block) storage devices like disk drives, CDROMs, or memory sticks, etc.

External resources