PDA

View Full Version : rm -rf FOUND* and everything else is deleted as well



finferflu
06-21-2006, 03:09 PM
Hi,

I am currently using Knoppix 5.0.1, HD install.

I want to report something that has both amazed and defeated me.

I was trying to remove some folders named FOUND001, FOUND002, and so on, up to FOUND032 or something. Those folders were in my vfat partition /dev/hda1, mounted on /media/hda1.

So I ran this command, in hda1 folder


rm -rf FOUND*

And I am sure I typed exactly that command, because I am aware of the dangers of the -rf flags.

After some loading I found out that the whole content of /media/hda1 was deleted!

I had some very important files (university docs), and this machine is also shared with another person (that now is extremely angry at me).

I don't know if there is actually anything I can do to retrieve even part of those precious files.

I was not thinking straight just after I realised what happened, so I rebooted with the Windows XP CD, to see if I could do anything, but I have no recovery disk. So while it was still loading for a new installation of Windows, I rebooted, and I hope I didn't alter anything in hda1.

Could somebody please give me some suggestions?

TheBoyMole
06-22-2006, 09:29 AM
So is your Windows install wiped as well? Was it on your hda1 partition?

There are quite a few undelete utilities for Windows that might help you out (e.g. http://officerecovery.com/freeundelete/) , I'm not sure about undelete utilities for Linux. I believe there is an NTFSundelete command, but that wont help you here.

If your absolutely determined to get the data back then I'd consider either getting hold of a second hard drive that you can install windows on, then run the undelete software above. I think there are also some DOS utilities available for undeleting on FAT32 partitions, so you might want to look into that and consider just using a simple DOS boot disk to get you going...

ckamin
06-22-2006, 12:59 PM
finferflu:

I believe that the "Folders" you mentioned are not folders at all. They were probably a series of .chk files. They are lost/unrefrenced data left over from an error scan of your hard drive. Your data is likely still on the drive and it would need to be recovered. That is unless you have written over the data by doing something foolish like re-installing Windows or some other operation. I have no firm suggestion for a recovery program, since I have not had the opportunity to recover data lost by the method you described. I would believe that any decent data recovery/undelete program would do the trick. There is also the data recovery services, but they are rather expensive.

finferflu
06-24-2006, 12:25 PM
I am sorry for my late answer.

Anyway, I have found a linux utility for recovering at least some data. It's called foremost, and I am now trying to think about how to retrieve my 20Gb of files, since I haven't got enough space on the linux partition, and I don't know how to connect an hard disk to my laptop (since I am using a laptop), and I don't know whether I can find a flash memory that big, but I guess so.

And yes, Windows is gone as well...

ckamin:
The folders I have mentioned were folders storing temporary internet files, in fact I checked them before deleting them, and there were only buttons, icons, banners and stuff like that in them. I haven't re-installed anything now, I just left it untouched, and while trying to recover files I mount the unit as read-only.

I am still wondering how that could happen, giving a command and having such an unexpected result...

OErjan
06-24-2006, 12:56 PM
just buy an external USB or firewireHDD, and use that.
there are such devises well above 500Gb
here you have one such (40Gb), it is powered by the USB port and is aboutthe size of a pocketbook.

http://www.dustin.se/dacsaportal/system/pages/products/wf_show_product_detail.aspx?ProdID=5010093553

yes i know it is in Swedish, it was what i could dig up in a hurry. it is more to show you what i mean.

finferflu
06-24-2006, 01:23 PM
Ok, thanks for that.

I was looking for usb hard drives, and I found one suitable to my needs (http://www.microdirect.co.uk/ProductInfo.aspx?ProductID=9525&GroupID=1427), now I just need to be sure it will be compatible with linux.

OErjan
06-24-2006, 01:49 PM
if it is FAT filesystem it is 99% that it will work, ntfs is not that good,
oh, the max size of any single file in FAT is 4G-1bit so no DVD ISO's (okok, aslong as they are less than 4g)... otherwise it should be ok.
if it is NOT fat filesystem you could always format it to that...

finferflu
06-24-2006, 02:09 PM
Thanks for that preciuos information, the description does not specify whether that hard drive is formatted as FAT or NTFS, but as you said, I can always format it.

As for the files, I haven't got any file bigger than 4Gb, so I should have no problem ^__^