In my PC I have 3 NTFS partitions 1 for Windows Boot Loader, next one is windows installation directory and the last one is for storing my whole data.

They were mounted like this

/dev/sda1 => /mnt/sda1

/dev/sda2 => /mnt/sda2

/dev/sda3 => /mnt/sda3

Yesterday I accidentally used following command

rm -rf /mnt/sda1 /mnt/sda2 /mnt/sda3

and now, When I am trying to open the Data partition it shows Input/Output error

Can I recover my data???

Any help would be appreciated...


There are many tools for data recovery but the key here is to don't touch anything, create a live usb/cd on another machine and use that. I recommend testdisk it can be found on gparted liveCD. Both are free.

| improve this answer | |
  • Hm okay I will do it.. thanks for your response. :) – B.A.B May 7 '15 at 5:05

First: get that disk out of the machine, put it in an external USB case, and only use it to access data, don't ever write to it.

Several months ago I partitioned an Ubuntu laptop and installed Windows on it. Then the owner told me to recover files from it. I used Photorec to recover the files. Almost all files were recovered. Filenames, paths to the file, and file dates were gone, so depending on what you're looking for this might be a problem. It does recognize filetypes, so jpeg, doc etc is identified and can be filtered out.

| improve this answer | |
  • Yeah, I tried testdisk, it can recover the deleted files. But I have some files left in the partition, So can I fix the input/output error without formatting the partition?? – B.A.B May 7 '15 at 5:04
  • I used Photorec to recover files (all types of files, not just photos despite the name). I haven't used Testdisk. I didn't have problems with I/O, and formatted the disk in the end. I don't think Testdisk will fix your I/O problems. Testdisk and Photorec can be used to recover files, other tools exist to fix or analyze disk and I/O problems. – SPRBRN May 7 '15 at 7:47
  • Hm.. right!! anyway thankyou for the answer. – B.A.B May 7 '15 at 10:09
  • First recover files, then mess with the disk! – SPRBRN May 7 '15 at 10:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.