vanowm
Contributor
Contributor

No access to mapped virtual drive from applications run as admin?

Hello.

When I use disk utility to map virtual drive as local volume (from virtual machine settings)

pastedImage_3.png

I can access the drive via explorer and regular command prompt, but not from applications that run as administrator (CMD as admin).

Any suggestions how to work around this limitation?

Thanks.

Windows 10 x64 (UAC disabled)

VMWare 12.5.2

Added a screenshot

Tags (2)
0 Kudos
7 Replies
HuanguoZhong
VMware Employee
VMware Employee

Thanks for coming to Workstation community.

I think this should be expected result for Windows OS.

But you can bypass it according to the link:

http://www.winability.com/how-to-make-elevated-programs-recognize-network-drives/

0 Kudos
vanowm
Contributor
Contributor

Hello.

Thanks for the response.

Sorry, I wasn't clear enough, I wasn't referring to network mapped drive, but to the disk utility section of a virtual hard drive in virtual machine settings. (I've added screenshot in my original post)

0 Kudos
HuanguoZhong
VMware Employee
VMware Employee

oh, get it.

I think you workaround it by launching Workstation for command window(run as administrator), and then do the mount with utilities tool, then the disk can be accessed.

0 Kudos
vanowm
Contributor
Contributor

I don't know how to launch it from CMD, but I've tried launch VMWare itself as administrator and from it map drive - it didn't make any differences.

However just now I've tried enable UAC and then launch VMWare as administrator, then I was not able access the mapped drive via explorer, but via admin CMD could access it. What a nightmare...

0 Kudos
wila
Immortal
Immortal

Hi,

While it might be a nightmare, this is just a standard windows security protection and also faced by users that do not use VMware products.

Mapped drives (eg. UNC shares that are mapped to a disk drive) are limited to the user that maps them.

HuanguoZhong actually already pointed to the workaround let me try an easier to read alternative.

windows - Command Prompt in Administrator mode doesn't see mapped drives - Super User

TL;DR you have to make a registry change if you want to disable this security protection.

edit: Oh and if the above registry editing does not work (for whatever reason) you could possibly use the net use syntax from above to map your share to a different drive from an admin command prompt.

--

Wil

| Author of Vimalin. The virtual machine Backup app for VMware Fusion, VMware Workstation and Player |
| More info at vimalin.com | Twitter @wilva
0 Kudos
rohitkaila
Contributor
Contributor

I have tried to use net use to map network drives from the link you sent, but for VMWare vmdk mapped files I do not see a way to use net use. The format is:

  net use Z: \\SuperServer\SuperShare

What does one replace for "\\SuperServer\SuperShare"?

0 Kudos
continuum
Immortal
Immortal

I consider that feature as broken since at least 3 or 4 years.

I would suggest to use Winimage instead.

Last time I was able to use it I had to run Workstation as admin and then use a cmd as admin and use it to open explorer against the mapped drive.

The trick was to launch explorer from an elevated cmd


________________________________________________
Do you need support with a VMFS recovery problem ? - send a message via skype "sanbarrow"
I do not support Workstation 16 at this time ...

0 Kudos