Pages

Subscribe:

Ads 468x60px

Wednesday, December 21, 2011

Restore Files From Recycle Bin Through Command Prompt

Recycle bin is the place where the files go when you delete it in Windows. If you accidentally delete a file, you can recover it by going to the Recycle Bin and simply clicking Restore. What if you delete a system file and your system stops booting?! Well, one of my friend was in that situation! Thats why i'm writing this blog post. :-)

You can access Recycle Bin through MS-DOS also! The recycled files are stored in directory called "RECYCLER" in Window XP and "$Recycle.Bin" in Windows 7.

Step 1: To get into MS-DOS while booting, press F8. You'll see an option called "Safe Mode with Command Prompt". Select it and press enter.
Step 2: You'll be asked to select the Operating system to start. Select your OS and press enter.
Step 3: Next, you'll see the screen where you select your user. Select your user name.
Step 4: Now, in the MS-DOS window like below, the directory will be C:\Users\(Your User Name)\ in Windows 7 and C:\Documents and Settings\(Your User Name)\ in Windows XP
Step 5: Type cd../.. and press enter.
Step 6: Type cd $Recycle.Bin in Win7 or cd RECYCLER in WinXP and press enter.
Step 7: Type cd and press tab. You'll see that the line is filled with a directory name like this "S-1-5-21-564594560-2944949298-4040108220-1000". Press enter.
Step 8: Type dir/a to see all the files including hidden files in that directory. The file you want to recover will also be there. But the name of the file may be changed.
Step 9: Here I deleted a system file named "BOOTSECT.BAK". Its been renamed as "$I1R8ZP3.BAK"
Step 10: Type copy (The Name of the File) (The location)
For eg., type copy $I1R8ZP3.BAK C:\
Step 11: Type cd../.. to go to the root directory.
Step 12: Type dir and enter. You'll see the file you copied from the Recycle Bin directory there.
Step 13: Type ren (The Name of the File) (The Name You Want)
For eg., type ren $I1R8ZP3.BAK BOOTSECT.BAK
Step 14: Thats it! The file is restored. Restart your computer and enjoy the Graphic UI of Windows again! :P

Pin It

14 comments:

Anonymous said...

This was extremely helpful. Saved 10 years of work which I hadn't backed up on my computer and was about to lose because I deleted a driver in the registry by mistake.

Thank you!

Anonymous said...

ini yang gw cari2..makasih banyak gan.. :D

Prasad said...

@1st: you're most welcome.. :-)
@2nd: english please.. :-))

Kenneth Caspe said...

can i ask something i delete a .doc file today but if i try to retrieve it in the cmd the date 6/25/12 has no modified files where can i saw that .doc file so i can retrieve it tnx sir in advance godbless

Kenneth Caspe said...

can i ask something is the $Recycle.Bin folder automatically deletes it's file inside of it because as i observed when i try to retrieve file using cmd i get it and i saw many deleted files but when i try to delete a file yesterday to the recycle bin it does'nt appear to the $Recycle.Bin folder so i can't retrieve it how can i see it and today when i go to the cmd the many deleted files in the $Recycle.Bin folder is gone and there are only 2 files remain that was deleted yesterday can i see agin the other deleted files and how i hope you understand my question tnx in advance

Prasad said...

@Kenneth: Recycle bin never deletes file on it own unless you enable the settings that does so. check properties of recycle bin for allocated space for deleted files in each drives. check for viruses also which deletes files from recycle bin.
.
if you need to recover files which you accidentally deleted use any of the File Recovery/Partition Recovery softwares.
.
(and btw, answering your question hoping that i understood it.. :D)

Anonymous said...

Lets say I wanted to recover the whole of the recycle bin, how can i do this in some sort of loop ? Can you do a copy * c:/RecoveredFiles/
And if you can how then do you do the ren part as you need to rename the file ??
Pleas ehelp, trying to write a .bat file to do this. Bascially recovering files from the recycle bin to somwehere else.

Anonymous said...

When I tried this on a winxp machine I was able to see my files and they were renamed to Dc3.doc Dc4.doc and so on. When I did the copy command it said the specified file could not be found

Any hints?

Anonymous said...

what is booting?

Reckless Abandon said...

Win 8. Got the file back, still kept going to system restore or whatnot and didn't get back to GUI of win 8 OS. Had to use system restore, which worked.

Joseph Vm said...

How can I recover permanently deleted -from recycle bin- audio files from using cmd?

Althessa Alcantar said...

Even a file that’s no longer in the Recycle Bin can still be recovered. Windows doesn’t overwrite the actual ones and zeros until another file needs the drive space. If the data is critical, a professional data recovery service may be the best solution. There are commercially available recovery software programs that attempt to recover inaccessible data from damaged or corrupted optical disks.

Richard Luis said...

Does your software recover data from recycle bin on all versions of Windows OS? Last week I searched one tool named as Remo Recover that can recover data from recycle bin on all versions of Windows OS

Gemmy Johnson said...

Thanks Rechard Luis as per your suggestion, I used Remo Recover tool and successfully recovered data from Recycle Bin on my Windows based computer within a short span of time....

Post a Comment