A more complete and thorough solution
“There is a mismatch between the tag specified in the request and the tag present in the reparse point”, is the full error message you get after clicking on a folder with a corrupted reparse point.
Sometimes you just can’t delete a file or directory, but let’s not focus on the details of the problem, just the solution. Suffice it to say its usually a file corruption issue; though occasionally it’s caused by too long of a file path structure or reserved name conflict due to some kind of POSIX hell.
Another reparse point error I’ve had is “location not available, the tag present in the reparse point buffer is invalid”. The solution is the same. Reboot into Windows Safe Mode and open the command prompt or by booting to an alternate boot device, which is the sure fire way to fix it if running CHKDSK if a reboot fails.
OneDrive appears to do this often after deleting large numbers of small files on SSD drives. Wish I knew why. Try pausing OneDrive first and then delete those large numbers of small files.
I just ran into such a problem trying to delete a folder from OneDrive and it’s sub-folders. It would not give me an error and would not remove the folder in my Windows 10 workstation. Not until I navigated down to the bottom directory and tried to delete the specific sub folder did I obtain the error above. Undeterred, I tried to delete it from the command line with rm and got this, “rm: cannot remove ‘src’: Input/output error”.
So I set the dirty bit to run chkdsk /f /r on the reboot. These switches do two things, /F is the repair switch, /R checks for bad sectors and copies the data to a new location and takes a long time to run, so use it as a last resort. I couldn’t get it to run. It It would go through the motions, but you can’t chkdsk /f /r on a nearly 1 TB volume in 14 seconds. I tried about all of the chkdsk variations, but couldn’t achieve a real scan and couldn’t delete the folder. Strange, but to be resolved later (Bad NvME drive?). I suspect that I’m not the only one who’s had this problem.
CHKDSK Issue Update:
Why CHKDSK wouldn’t run? ADATA SSD drives do not work with AMD onboard Raid 0 and probably variations similar to this. Use Samsung SSD.
Displays the help dialog and provides the following
Fixes errors on the disk.
On FAT/FAT32: Displays the full path and name of every file on the disk.
Locates bad sectors and recovers readable information (implies /F, when /scan not specified).
NTFS only: Changes the log file size to the specified number of kilobytes. If size is not specified, displays current size.
Forces the volume to dismount first if necessary. All opened handles to the volume would then be invalid (implies /F).
NTFS only: Performs a less vigorous check of index entries.
NTFS only: Skips checking of cycles within the folder structure.
NTFS only: Re-evaluates bad clusters on the volume (implies /R)
NTFS only: Runs an online scan on the volume
NTFS only: (Must be used with “/scan”) Bypass all online repair; all defects found are queued for offline repair (i.e. “chkdsk /spotfix”).
NTFS only: (Must be used with “/scan”) Uses more system resources to complete a scan as fast as possible. This may have a negative performance impact on other tasks running on the system.
NTFS only: Runs spot fixing on the volume
NTFS only: Garbage collect unneeded security descriptor data (implies /F).
Runs an offline scan and fix on the volume.
FAT/FAT32/exFAT only: Frees any orphaned cluster chains instead of recovering their contents.
FAT/FAT32/exFAT only: Marks the volume clean if no corruption was detected, even if /F was not specified.
The /I or /C switch reduces the amount of time required to run Chkdsk by skipping certain checks of the volume.
Safe Mode Command Prompt
If your corrupted file system is on the same drive that Windows is installed on the only options are Safe Mode or an alternate boot media, like a USB drive with one of the options further below.
Be sure to save your work before you proceed with this Solution.
The system drive is usually Drive D: when using Safe Mode Command Prompt, but if it’s a weird machine, it could be another drive letter. Just type E: and press enter. Type in DIR and press enter. If there isn’t a folder named Windows present then you are not on the system drive. Repeat this with each letter of the alphabet until you find the drive you want. In even stranger scenarios, your data might not be on the system drive. Good luck warrior, you have a major battle then.
I would just find every drive letter in that situation and run CHKDSK /F on each one.
If That Didn’t Work, Then…
Run CHKDSK From Boot Media
Use Boot media with Windows PE or Windows RE to run CHKDSK from. For reasons unknown, the CHKDSK on the reboot doesn’t fix the reparse points in the file system. To be fair, the native OS has worked for some, but has never worked for me, so I just use an alternate boot device and run CHKDSK from it and I don’t try it any other way anymore.
Some Alternative Boot Options
- Hiren’s BootCD PE
- Microsoft PE (Instructions)
- Active Boot (Costs some moolah, but easy to load drivers with)
I’ve been using Active Boot for more than 15 years so I opted to boot to a USB drive with raid drivers installed. This allowed me to run a full CHKDSK with CHKDSK (DriveLetter): /scan /perf. Problem solved and the folder was able to be deleted. Now to figure out why the native OS couldn’t run CHKDSK. The results will look something like this if there is a reparse error involved.
Your results should resemble this
The type of the file system is NTFS. Stage 1: Examining basic file system structure ... Deleting corrupt attribute record (0xC0, "") from file record segment 0x1A97CB. Deleting corrupt attribute record (0xC0, "") from file record segment 0x1F65EC. Deleting corrupt attribute record (0xC0, "") from file record segment 0x22735D. 2488832 file records processed. File verification completed. 22125 large file records processed. 0 bad file records processed. Stage 2: Examining file name linkage ... Correcting reparse point file record segment 1A97CB. Correcting reparse point file record segment 1F65EC. Correcting reparse point file record segment 22735D. Deleting an index entry from index $R of file 1A. Deleting an index entry from index $R of file 1A. Deleting an index entry from index $R of file 1A. 712194 reparse records processed. 3043510 index entries processed. Index verification completed. 0 unindexed files scanned. 0 unindexed files recovered to lost and found. 712194 reparse records processed. Stage 3: Examining security descriptors ... Security descriptor verification completed. 277340 data files processed. CHKDSK is verifying Usn Journal... Usn Journal verification completed. Windows has made corrections to the file system. No further action is required.