I accidentally deleted a few important work related folder from my Ubuntu 14.04. I wanted to recover them. All the options on net gives instruction for recovering files.

I tried scalpel but I don't remember any of the file names so i could not recover any files. Is there a way to list the folders i deleted and recover the one i wanted? I need these files please help me.

  • How did you delete? The rm command?
    – Kaz Wolfe
    Commented Dec 16, 2016 at 18:40
  • please specify how to recover folders.
    – karthick
    Commented Dec 16, 2016 at 18:41
  • shift+delete so it is not in the trash.
    – karthick
    Commented Dec 16, 2016 at 18:41
  • boot a live usb ASAP and see help.ubuntu.com/community/DataRecovery . A directory is itself just a file with a list of the contents.
    – Panther
    Commented Dec 16, 2016 at 18:53

1 Answer 1


If you've permanently deleted a file (using something like rm or Shift-Delete), the file is still there, but marked as "free", meaning it can be overwritten by any other file operation. In order to prevent this data from being destroyed, SHUT DOWN YOUR SYSTEM NOW.

Boot into a live session (USB/CD/DVD/etc) and use a tool like foremost or photorec to attempt to pull the lost data from your drive. Do not mount the partition from your live disk. Operate on the raw block device itself.

You can get information about these two utilities using man photorec or man foremost after the eponymous packages have been installed to the live media.

Your folder itself is likely gone (as it's just virtual), but the files within might still be okay, but you might need to sort through a lot of cruft to find those files.

  • photorec is unreliable as it has no way of recovering fragmented files, and the recovery mostly ends by having corrupted files. Don't recommend it to others. Commented Oct 15, 2017 at 19:08
  • @user6039980 While this may be the case, photorec does work and has saved me and numerous other people many times in the past. Even if it's not the best tool, it's still better than nothing.
    – Kaz Wolfe
    Commented Oct 15, 2017 at 19:12
  • That might be true only if you are recovering text-based data, which can be simply done more reliably using grep. Commented Oct 15, 2017 at 19:36
  • For instance, partition recovery software can find deleted files from the filesystem - so even if the filesystem is fragmented, the user can view his deleted files directly from the software and get it 100% complete, not corrupted as what the file-signature data recovery (photorec and foremost case) does .. Commented Oct 15, 2017 at 20:03

Not the answer you're looking for? Browse other questions tagged .