Ever encountered a problem on your computer that made it impossible to access a partition or complete hard drive? Or something that erased your Master Boot Record which had the result that you were not able to boot your operating system as usual? Something like this can happen if you try to install a new operating system to dual boot both systems for example, if your system gets infected by a malicious virus, if the hard drive is slowly falling apart, or if files become corrupt on the PC.
If you do not know what caused this and do not know tools that can fix this your only option is to install the operating system again. That is often not the best course of action as you may or may not fix the issue doing so. While it may repair corrupted files for example or the master boot record, it won't resolve hard drive errors.
Testdisk, which is an open source data recovery live CD, may be the tool you need when you encounter a situation like the one described above. Testdisk will only help if the errors are software based, if you encounter a problem that is hardware based you are out of luck.
Just download the version of Testdisk that is offered for your operating system and execute it. If you can't boot the system you may want to use the gparted linux distribution instead which includes testdisk and can be booted from CD (recommended).
Please note that you need to know what you are doing, you should have at least basic knowledge about partitions, file systems and the like to use a tool like Testdisk. You may erase data on other partitions otherwise. After selecting whether you would like to create a new log, append to an existing log or use no log you have to choose one of the hard drives that is currently connected to your computer.
You may want to disconnect other hard drives from your computer to avoid mistakes that could erase the data on those drives. Select a partition type afterwards, Intel/PC, Apple, None, Sun and Xbox.
After that you have many options - all of them are explained in great detail on the testdisk wiki. You may analyze the partition, which displays partitions and searches for corrupt ones, write a test MBR, change the disk geometry, erase all data and access advanced filesystem utilities for Fat, NTFS and EXT2/EXT3 which leads repair options to repair partitions.
Here is a quick rundown of what TestDisk has to offer:
- Recover deleted partitions and fix the partition table.
- Recover Fat32 and NTFS boot sectors
- Copy files from deleted partitions and undelete files.
- Rebuild Fat boot sectors.
So, it is ideal if you need to recover data from a drive that is not accessible anymore, and to recover partitions that are not accessible anymore on the computer.