Problem with MapNetworkDrive

Mar 16, 2011 at 11:37 AM

Hi.
I have a problem with Vestris.VMWareLib.Tools.Windows.MappedNetworkDrive.MapNetworkDrive. It throws this exception from time to time: "System.ComponentModel.Win32Exception : Multiple connections to a server or shared resource by the same user, using more than one user name, are not allowed. Disconnect all previous connections to the server or shared resource and try again".


The stack trace is:
at Vestris.VMWareLib.Tools.Windows.MappedNetworkDrive.MapNetworkDrive()

at Vestris.VMWareLib.Tools.Windows.MappedNetworkDrive..ctor(VMWareVirtualMachine vm, MappedNetworkDriveInfo info)


I am using:
Vestris 1.5

VMware Workstation 6.5.3.8888

VMware VIX 1.7.0.8977

Windows Server 2008 R2 64 bit

I've only seen the error on this OS and it only occurs sometimes. Any ideas how to prevent this error from showing? Do you need more info?

Thanks,

Jacob



Coordinator
Mar 16, 2011 at 12:10 PM

The functionality of MappedNetworkDrive is the same as typing "net use \\server\path /user: ...". This error means that you have mapped the drive under different credentials in a different process or thread. So you need to track down the other party, could be as simple as someone opening the remote path in Explorer or something that does it in code.