Are there any tools, methods, incantations to recover recently deleted files on Ubuntu?
If it makes any difference, I want to recover a Keepass 2.x database file. But would be better to have a method/tool that works on any kind of file.
|
Are there any tools, methods, incantations to recover recently deleted files on Ubuntu? If it makes any difference, I want to recover a Keepass 2.x database file. But would be better to have a method/tool that works on any kind of file. |
|||||
|
|
TestDisk can sometimes recover recently deleted files. |
|||||||||||||||||
|
|
extundelete is really great if your file system is ext3 or ext4. Note: extundelete requires you to unmount your drive to work properly (this is a good idea to do ASAP anyway, to avoid potentially overwriting the hopefully-recoverable bytes in the deleted files). Unmounting the drive on a live system can be tricky... you'll often get the ' The trick to getting around this is to do a 'lazy' unmount:
where:
|
|||||||||||||||||||||
|
|
I have used foremost to recover damaged hard disk both under NTFS (windows), FAT32 (Flash card from a Nokia phone) and ext3 with great results. Command line only, but quite it's easy, something like this:
It will order the recovered files on folders by file-type. Openoffice docs are recovered as zip files. As you need to execute it as root (in order to direct access the hardware), output files are also owned by root, so you will likely need to change their ownership afterwards. |
|||||||||||||||||||||
|
|
To recover the directory you can use
Note: In place of
|
|||||||||
|
|
R-Linux(Recovery studio) is one of the best. I have used this tool many times before. I worked at a company where they used the commercial version, 9/10 times it recovers everything you want. Truly superb application. Saved mine, and friends behinds many times before.
Features (from their website): R-Linux recover files:
R-Linux Advanced features:
|
||||
|
|
|
If you deleted some file by accident but still know some strings which were written in that file you can use:
|
|||||||||||||||||||||
|
|
If using secondary internal HD (suspect the same for external HD) for recovered file import (from main HD, where the files originally were), it’s necessary to make a directory, into which the files will be put in on secondary HD.
To do it, you need to have BIOS setting for booting from CD first!
1. Start Live Ubuntu Rescue-Remix CD, give command to boot, then when it boots into terminal, check your HDs by command – Code: Realize what HD is main, and which is secondary, and what partition to check for files and into which to recover them – linux ext3 or Windows NTFS! Mine was Linux. Have enough room on it! (Then you can try to run Photorec (“sudo photorec”) and hopefully you’ll be able to see all your HDs. I was not that lucky, so I had to make directory and mount sec. HD.)
If alright, terminal prompt simply returns.
If alright, terminal prompt simply returns.
Go thru settings, and only choose file types that you want, otherwise you’ll have thousands of files to sift thru! For more details you may please visit: http:/www..ubuntumanual.org/posts/357/recover-your-deleted-files-in-ubuntu |
||||
|
|
|
|
|||||||||||||||||
|
|
Autopsy and the Sleuthkit tools are great for recovering deleted files, with a user-friendly UI, as well as being available in the repos. |
|||||||||||||
|
|
Recently I used ext3grep to recover a large SQLite 3 file that was deleted from an ext3 file system. I had tried many other undelete tools, all which couldn't recover the file (from a dd image of the disk). In order to use ext3grep, I needed to download and compile the source. Carefully reading http://www.xs4all.nl/~carlo17/howto/undelete_ext3.html from top to bottom in order to understand how the ext3 file system works and how to use the journal to find where deleted files use to be on the disk was also required. This is not a simple solution, but very, very powerful. If you're prepared to invest a few hours to study the document and compile the program, it's well worth it. |
|||||||||
|
Thank you for your interest in this question.
Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).
Would you like to answer one of these unanswered questions instead?