Sometimes users are faced with the loss or accidental deletion of necessary files. When this situation occurs there is nothing left to do but to try to restore everything with the help of specialized tools. They are scanning the hard disk partitions, corrupted, or find the previously deleted objects and try to return them. Not always such an operation is successful because of fragmentation or total loss of information, but to try definitely.
Restoring deleted files in Ubuntu
Today we’d like to talk about the available solutions for the operating system Ubuntu, which is based on the Linux kernel. That is, the methods are suitable for all distributions based on Ubuntu or Debian. Each utility operates differently, so if the first did not bring any effect, be sure to try the second, and we, in turn, will present the most detailed guide on the subject.
Method 1: TestDisk
TestDisk, as the following utility is a console tool, but not the whole process will be carried out by issuing commands, something which the implementation of the graphical interface is still there. Let’s start with the installation:
sudo apt install testdiskto start the installation.
The functionality of the considered utility simply amazing, because it can recover not only files, but entire partitions, but also great to interact with the file systems NTFS, FAT, and with all versions of Ext. In addition, the tool just returns the data, but provides bug fixes, which avoids further problems with the performance of the drive.
Method 2: Scalpel
For the novice user to deal with the utility Scalpel is a bit more tricky, because here every action is activated by entering the corresponding command, but do not worry, because we will thoroughly describe every step. As for the functionality of this program, it is not tied to any file systems and works equally well on all types and supports all popular data formats.
sudo apt-get install scalpel.
sudo gedit /etc/scalpel/scalpel.conf.
lsblk. In the list find the required designation of the drive.
sudo scalpel /dev/sda0 -o /home/user/Folder/output/, where sda0 — the number of desired section, the user — name the user folder, and Folder is the name of a new folder which will be placed all the recovered data.
sudo nautilus) and check with found objects.
As you can see, to sort out a Scalpel will not be easy, but after getting acquainted with the control activation of the action commands is no longer seem so complicated. Of course, none of these tools does not guarantee complete recovery of all lost data, but at least some of them each utility must return.