Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I mistakenly run rm -rf on a wrong folder and than cancel the operation after two seconds. The folder is quite big with many subfolders and maybe 1% was deleted.

How can I know what subfolders rm attempted to delete first? That can help me to determine what files I need to restore.

share|improve this question
This does not answer your question, but might help you somehow:… (How to recover a removed file under Linux?) – douglaslps Oct 31 '13 at 13:07

Won't be easy to restore names of already removed directories, but executing ls -l * probably will give a clue how shell expanded * wildcard.

share|improve this answer
If that was the case, I got lucky. – user2783132 Oct 31 '13 at 18:30

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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