我有一個Hyper-V的虛擬機與流浪1.8.4構建,我試圖用「流浪者的PowerShell」命令啓動在虛擬機上配置(使用puppet)的腳本。一些目錄很容易被訪問,比如C:\ users \ vagrant。我完全控制了這個文件夾和所有後續的目錄。每當我嘗試啓動腳本,甚至使用'dir'命令訪問某些文件夾時,我都會收到一個錯誤,指出「權限被拒絕」。流浪PowerShell的問題帶有Hyper-V虛擬機(流浪者版本1.8.4)*權限被拒絕*
下面是一個簡單的「流浪漢的PowerShell -c‘C:\供應\殼’」的輸出命令:
vagrant : The following WinRM command responded with a non-zero exit status.
+ CategoryInfo : NotSpecified: (The following W...ro exit status.:String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
Vagrant assumes that this means the command failed!
dir 'C:\provision\shell'
Stdout from the command:
Stderr from the command:
#< CLIXML
<Objs Version="1.1.0.1" xmlns="http://schemas.microsoft.com/powershell/2004/04"><S S="Error">dir : Access to the
path 'C:\provision\shell' is denied._x000D__x000A_</S><S S="Error">At line:1 char:40_x000D__x000A_</S><S
S="Error">+ $ProgressPreference='SilentlyContinue';dir 'C:\provision\shell'_x000D__x000A_</S><S S="Error">+
~~~~~~~~~~~~~~~~~~~~~~~~_x000D__x000A_</S><S S="Error"> + CategoryInfo :
PermissionDenied: (C:\provision\shell:String) [Get-ChildItem], UnauthorizedAccessExcepti _x000D__x000A_</S><S
S="Error"> on_x000D__x000A_</S><S S="Error"> + FullyQualifiedErrorId :
DirUnauthorizedAccessError,Microsoft.PowerShell.Commands.GetChildItemCommand_x000D__x000A_</S><S S="Error">
_x000D__x000A_</S></Objs>
如果有人可以幫助我弄清楚爲什麼我收到這些拒絕「權限」錯誤,這將是偉大的!
任何援助將不勝感激。
嗯,我永遠找不到一個原因,爲什麼我無法遠程訪問共享文件夾...我**是**但是能夠提供一個腳本,將共享文件夾的內容複製到我有一個目錄訪問。有點醜陋和不雅,但它有效 –