| 4 | |
| 5 | == File recovery with Extundelete == |
| 6 | Extundelete lets you recover files (directories) that you've accidentally deleted on an ext file system. The best way to use the tool is to have a live CD with the tool on it, although it does not seem to come packaged with Linux by default. |
| 7 | |
| 8 | 1. Boot the machine off of live CD. |
| 9 | 2. Install `extundelete`. On Ubuntu, you need to edit sources.list, since it is not part of the standard repositories. [[BR]] |
| 10 | 3. Restore the files on the partition: |
| 11 | {{{ |
| 12 | # sudo extundelete --restore-all /dev/sda1 |
| 13 | }}} |
| 14 | This restores everything that has been deleted in /dev/sda1, given the tool finds them. All recovered files are placed in a recovery directory that you can package and back up before rebooting the machine. |