Here’s the step-by-step CMD process to fix a corrupted pendrive without formatting:
✅ Step 1: Connect and Identify the Drive
- Plug in your pendrive.
- Check the drive letter (e.g.,
E:
) from File Explorer.
✅ Step 2: Run CHKDSK to Repair Without Formatting
This is the most effective way to fix file system errors without erasing your data.
- Open Command Prompt as Administrator:
- Press
Windows + S
, typecmd
- Right-click Command Prompt → Choose Run as Administrator
- Press
- Type this command:
chkdsk E: /f /r /x
🔁 ReplaceE:
with your pendrive’s actual drive letter.
What this does:
/f
fixes file system errors/r
checks for bad sectors and recovers readable info/x
forces dismount so CHKDSK can fix it
✅ Step 3: Check File Visibility
After CHKDSK completes:
- Open File Explorer → Check if your files are now visible.
- If files are still hidden, try this command:
attrib -h -r -s /s /d E:\*.*
This removes Hidden, Read-only, and System attributes from all files and folders.
❗ If CHKDSK Shows: “The type of the file system is RAW”
That means the file system is severely corrupted and Windows cannot read it.
In that case:
- Don’t format it yet.
- Use data recovery tools like Recuva, PhotoRec, or EaseUS to recover files first.
If pendrive shortcut folder created
Follow below step to fix :-
- Open cmd Run As Admin
- Determine the Drive latter of infected USB Drive or computer
- type the drive latter follow by a colon(e.g “e:”), and press Enter.
- use attrib command( e.g replacing x with actual drive)
- e.g attrib -h -r -s /s /d x:*.*
- -h : Remove the hidden attribute.
- -r : Remove the read-only attribute.
- -s : Removes the system attribute.
- /s : Applies the command to all subdirectories.
- /d : Applies the command to directories as well.
- X : \*.* : Specifies all files and subdirectories within the drive X.