I have one folder on an SSD that refuses to be deleted. Other folders can be removed normally, but attempts through both PowerShell and Command Prompt fail with a message saying the file or directory is corrupted and unreadable. I have already tried running both tools as administrator. What is the safest way to remove the folder and check whether the drive or file system has a problem?
1 Answer
This usually indicates file-system corruption rather than a permissions issue. First back up any important data from the SSD, then run a file-system check on the drive from an elevated Command Prompt, replacing D: with the correct drive letter: `chkdsk D: /f`. If Windows says the volume is in use, allow it to schedule the scan and restart the computer. After the repair completes, try deleting the folder again. Also check the SSD’s health with the manufacturer’s diagnostic tool; repeated corruption can indicate a failing drive.

The folder is on an SSD, and I already ran both PowerShell and Command Prompt as administrator. I’ll back up the drive and try the file-system check.