VeraCrypt icon indicating copy to clipboard operation
VeraCrypt copied to clipboard

Residual drive inaccessible

Open mrx23dot opened this issue 2 years ago • 4 comments

I was mounting up/down encrypted volumes, but last one stuck. I cannot mount again. I cannot open it. Breaks my automation scripts. Probably some hard to reproduce windows bug, but still we should be able to drop the drive.

Expected behavior

Drive should go away after forced unmount.

Observed behavior

Drive stays, inaccessible, cannot be removed

Steps to reproduce

Mount up/down multiple times, happened randomly.

Screenshots

2022-01-17_203836

when opening it: 2022-01-17_203920

cmd says: s: The system cannot find the path specified.

Doesn't show as valid: 2022-01-17_204130

Your Environment

Please tell us more about your environment

VeraCrypt version: 1.25.7 win7 x64

I can try suggestions till the end of the day.

mrx23dot avatar Jan 17 '22 20:01 mrx23dot

S: missing from Vera: 2022-01-17_204304

mrx23dot avatar Jan 17 '22 20:01 mrx23dot

Just updated VeraCrypt and also experienced this, kind of. I have a ghost Z: drive on "My computer" but that letter is still available on VeraCrypt. Restarting explorer.exe gets rid of it. I'm trying to reproduce the "problem" but it's not doing it anymore.

nikkopt avatar Feb 13 '22 19:02 nikkopt

This is seem to belong to the same family of issues the first one documented at https://veracrypt.fr/en/Issues%20and%20Limitations.html Basically this is caused by internal caching of Windows Mount Manager and running the command "mountvol.exe /r" as an administrator should solve it (sometime killing explorer.exe or rebooting the machine maybe needed). On VeraCrypt side, we already call necessary Windows APIs when a volume is dismounted in order to free its drive letters but for unknown reasons, Windows Mount Manager may sometime keep invalid references to the drive letter.

idrassi avatar Feb 13 '22 21:02 idrassi

mountvol.exe /r sounds good enough, could we execute it after any dismounting?

In a best effort way (in case not running as admin), ignore return values. It shouldn't have any downside.

https://superuser.com/questions/996189/how-to-remove-phantom-drive-letters

mrx23dot avatar Feb 14 '22 09:02 mrx23dot