windows使用net use命令System error 85 has occurred. The local device name is already in use.There are open files and/or incomplete directory searches pending on the connection to 错误

两种解决方法

远程服务器设置导致

1.修改注册表修改远程服务器设置
将下面的注册表下的值从1改为0

HKLMSystemCurrentControlSetControlSessionManagerProtectionMode

2.修改本地脚本

删除所有的磁盘映射,而不是特定的某一个

:: 删除所有设置的磁盘映射
net use * /delete /y
原文地址:https://www.cnblogs.com/ls11736/p/13739263.html