Command Prompt is the default program, which is used to run various applications by using different commands. It can also resolve the issues related to Windows including External Hard Drive, Memory Cards, and Flash Drives. It is an alternate way to execute the software.
Most of the users tend to use the latest way to run the software on their system, but they never stay away from executing the application using Command Prompt. So, it also helps users to retrieve the files, which are lost due to accidental deletion, virus attacks, etc.
Consider the below given real-time example, where one of the users had deleted files and he wants to know how to recover deleted files using command prompt.
“Hello friends..! I got stuck in a big problem, as my carelessness had cost me a lot. Yesterday, I have accidentally deleted some most important files. The files which I had deleted are very important to me that I need very much for my work. So I want to restore deleted files using the Command Prompt. To do so, I am searching software to recover deleted files using Command Prompt and access deleted files again on my computer system. Please help me to recover my deleted files…!”
There are many users who have faced the same problem like this. So, this article will surely help the users to find a way to recover lost files through the command prompt. Before going further, first, understand the file structure. A file has two parts:
- File directory which contains the file name & the list of the blocks
- The actual blocks which contain the contents or data
When any file is deleted, then the only directory is removed whereas the actual block still contains the data. Thus, the directory records are marked “available” & they are invisible from the operating system. In such situations, users can easily recover deleted files using the command prompt.
Process To Recover Deleted Files Using Command Prompt
The command prompt is one of the most impressive methods to recover lost or deleted files from the external drive. The command Prompt executes several different commands to perform the recovery task. So, there are some commands given below, which can recover lost files:
Before executing attrib command to recover deleted files. Make sure you are using the right command. Because a wrong step will lead you to a serious problem. Also, the CMD commands are written in the scripting language. So, you have to follow the complete command without any change.
Steps to Retrieve Deleted Hard Drives Files Using Attrib Command on CMD
If a user has accidentally deleted files from the storage drive such as USB, flash sticks, hard drives, etc. Then, in order to perform recovery, follow these commands in command prompt:
- First of all, press Windows key + R and type CMD in the search box
- After that, in the Command Prompt window, type chkdsk “drive letter” /f & press Enter key
For example: C: \ USERS\ PROGRAM FILES\ chkdsk D: /f
- Now, press Y key until the command lines start again
- Then, again type the drive letter and press the Enter key. Then, the command line will go back to the start
- Now, type drive letter: \ >attrib –h –r –s /s /d *.*. This command will recover all the lost files in the storage drive
- r is Read-only attribute: Files are readable & cannot be changed
- –s is the ‘System’ attribute to the selected files
- –h assigns the ‘Hidden’ attribute to the selected files
- ‘/S’ assigns to search the specified path including subfolders
- ‘/D’ command includes process folders
- Finally, when the recovery process is completed, then a new folder is created on your external drive with all the recovered files. Most probably, the files will be in CHK format. Now, change the file format & save the files at the desired location on your system.
Recover Deleted Files From Recycle Bin Using Command Prompt
In some situations, where the recycle bin becomes full, then Windows will delete the files to make space for the recently deleted files. However, these removed files are still recoverable until the recycle bin is emptied.
In order to recover deleted files using command prompt, follow these commands:
- First of all, in the command prompt window, type the command start shell:RecycleBinFolder & press Enter key
For example: C:\> start shell:RecycleBinFolder
- Finally, choose the files and recover them.
Note: – What if attrib command fails to recover deleted files? In such a situation, you need a powerful way to get deleted files back from hard disk. Move to the below section and know the easiest way to retrieve permanently deleted data from hard drive easily.
Retrieve Lost Files When Command Prompt Does Not Help You
Even though users can restore deleted files through command Prompt but sometimes users are not much aware of the commands and also not much familiar with CMD commands. Also, the command prompt cannot restore deleted files from a formatted storage drive. Therefore, it is suggested to use Windows Data Recovery Software. This tool can help to recover the deleted files from the external drive without any hassle. It does not require any familiarity with the command lines. Moreover, it is quite easy to use and effective utility.
Perform the simple steps listed below instead of performing hectic attrib command.
- Download the utility and Install on Windows 10, 8, 8.1, 7, etc. OS
- Select the Hard Disk Partition from Which files deleted and Hit Scan
- Preview complete files after successful recovery
- Save at any location on your Windows computer
Note: – In these simple four steps you can retrieve lost files without performing CMD commands.
How to Recover Hard Drive Deleted Files Using CMD? – Users Queries!
The questions listed below taken from different discussion sites. After reading these queries you will come to know the different scenarios of data deletion and recovery using command prompt to run attrib command.
“Hello, My name is Jack Miler and I am a shop keeper. I used the external hard disk to store my important documents. Last night, I deleted some files accidentally. Now to want to know how to recover deleted files from external hard drive using CMD.”
“I don’t know anything about Command Prompt. But, I am curious to know how can I recover deleted files using command prompt. Please suggest a solution for both internal and external HDD.”
“Is anyone available here to help me. My son deleted data from the hard drive and I want a free solution to get deleted files back without using the software. I heard about attrib command, but don’t know how to use. Please suggest me data recovery command prompt.”
“Hi all, I am using Windows 10 on my computer. I come to know that, the data recovery using command prompt is possible. Is it really possible?, if yes then please let me know the command and help me to understand how to recover deleted files using CMD in windows 10?”
“I know how to run attrib command. I am doing all the things in the right way. But I am unable to recover deleted files using command prompt on Windows 8.1 laptop. Please let me know the correct procedure. So that I can recover deleted data using command prompt.”
The Final Words
Sometimes, users have accidentally deleted some imported data. After that, they want to recover them. Thus, this article tells how to recover deleted files using the command prompt. Along with the deleted file, users can also restore the formatted data and even restore data from the virus-infected devices in Windows 10, 8, and 7 by using Command Prompt. If the command prompt does not give an appropriate result then users can go to the third-party tool. The commercial software is capable of recovering all types of deleted or lost files that include applications, documents, media files, archive files, etc.
With the help of the above mentioned blog, you can restore files from the command prompt. In this post, we have described an efficient solution to resolve this issue.
Try the above Freeviewer software you can recover deleted, corrupted and formatted data without any file size issue.