Advertisement

How do I recover the file deleted by rm -f

Started by September 14, 2008 02:52 AM
3 comments, last by SimonForsman 15 years, 12 months ago
How do I recover the file deleted by rm -f? I delete a file with rm -f. Now I want to save the file to the disk. How can I do that?
akira32 編程之家 Yahoohttp://tw.myblog.yahoo.com/akira32-akira32
Depends.

If there is another hard link to the data you've removed with rm, then the data is still present and referenced by that hard link. All you would have to do is restore the hard link you've removed with ln.

If there are no other hard links, then rm will destroy the corresponding inode (which includes the data regarding where the data is on the disk) and usually mark the newly freed memory blocks as the next to be overwritten when a file is created—and files are created on UNIX all the time.

You may want to look int othe documentation of your file system to see if it suports undeletion.

Your best bet is to recover your data from backups.
Advertisement
You could try R-Linux
http://www.data-recovery-software.net/Linux_Recovery.shtml

Its a free data recovery tool for Linux

If you are using some other OS you can try googling for "<name of your os> data recovery software"

There are both free and comercial products available for all major(and some minor) platforms.
[size="1"]I don't suffer from insanity, I'm enjoying every minute of it.
The voices in my head may not be real, but they have some good ideas!
Thanks. But I use the UNIX (HP station). Does somebody know the data recovery tool for UNIX?

akira32 編程之家 Yahoohttp://tw.myblog.yahoo.com/akira32-akira32
Quote: Original post by akira32
Thanks. But I use the UNIX (HP station). Does somebody know the data recovery tool for UNIX?


There are plenty of unix systems these days, if it is HP-UX you could try
http://www.stellarinfo.com/hp-unix-data-recovery.htm

Allthough if you have been using the drive after deleting the file its quite unlikely that its possible to recover it anymore.
[size="1"]I don't suffer from insanity, I'm enjoying every minute of it.
The voices in my head may not be real, but they have some good ideas!

This topic is closed to new replies.

Advertisement