Saturday 22 December 2012

Recover Accidentally Deleted Files From Any OS With PhotoRec [Windows, Mac, & Linux]

recover deleted filesSometime back when i switched from Windows to Linux OS for learning some of the interesting features about Linux OS.One day i accidentally deleted some of my important documents.After that i had searched a lot and finally got a good way to recover files in Linux OS also.The software using which i had recovered my files is Photorec.

Previously i had write about the recovery tools like Recuva and Pendora Recovery. Recuva works fine with Windows only but for OS like linux, Photorec is the good choice to recover your files. Photorec is not only a Photo recovery tool as suspected from it's name but this tool recover all other types of files like Audio,Video,.exe, etc.

PhotoRec comes bundled with another, more advanced recovery tool called TestDisk. For now we’ll be focusing on PhotoRec which will suit most data recovery tasks. TestDisk is on another level of data recovery and capable of recovering whole partitions which is overkill when all you want to do is recover accidentally deleted digital camera snaps.

I’ve used PhotoRec a few times in the past, mostly to test what it’s capable of. For those of you looking for “proof” of the software’s effectiveness then I’ll give you a little insight into my recovery options.

recover deleted files

Recovering With PhotoRec:

First download PhotoRec and extract it to anywhere except the drive you want to recover deleted files from. Don’t forget, the more data you write to a volume you’d like to recover from, the more data you are potentially destroying. Execute PhotoRec and you should see a window appear in your default console app (Terminal for OS X and Ubuntu users, Command Prompt on Windows).

how to recover deleted files
PhotoRec requires root (admin) access to your PC, and OS X users will see the screen I’ve included above. At this prompt on a Mac system simply hit enter to restart, input your password and you’re good to go. On Windows, you will need to run PhotoRec from an administrator account and on Linux you will need to do this from the command line using the sudo command, e.g. “sudo testdisk-6.13/photorec-static” followed by your administrator password.
how to recover deleted files

Once you’ve got PhotoRec running it’s a case of simply following the on-screen commands. First choose the device you would like to recover deleted files from, in my case it was the 2GB drive listed in the screenshot above.

restore deleted files

Next you’re prompted to choose a partition, along with a few options along the bottom of the screen. The Options screen has preferences for keeping corrupted files and enabling additional controls, while File Opt allows you to omit certain file types from the recovery process
restore deleted files

If you’re simply out to see what you can recover, I’d recommend leaving everything as default and hitting Search. The next screen asks whether you’re using an EXT2/EXT3 file system, or something else. For NTFS, FAT, HFS+ and other drive types choose Other.
restore deleted files
Next up you’ll be prompted whether to scan the whole volume or just unallocated space. On large drives a whole partition scan will take a long time, though on USB drives and memory cards it’s probably worth waiting a couple of hours if it means regaining lost data

The final prompt asks where you would like to recover the data to. The only really important thing to remember here is not to recover to the volume you are recovering from! I made a folder on my desktop and let PhotoRec go to work. Hit C to start the process, then let PhotoRec do its thing.







The final prompt asks where you would like to recover the data to. The only really important thing to remember here is not to recover to the volume you are recovering from! I made a folder on my desktop and let PhotoRec go to work. Hit C to start the process, then let PhotoRec do its thing. 

I was lucky this time, I managed to recover more than 600 photos, despite erasing and writing to the volume twice. PhotoRec is an invaluable free tool to have at your disposal, especially on Mac OS X where so many companies charge for file recovery sof.

recover deleted files

Have you had any close calls with data loss? Have you used PhotoRec or TestDisk in the past? Share your “oops!” moments in the comments, below. 


0 comments:

Post a Comment