powershellpowershell-remoting

Enter-PSSession to remote server fails with “access is denied”


I want to use winrm remote vm, I can connect to the localhost, but I can't connect to the other remote machine, the error is "access is denied".

Please help me. enter image description here


Solution

  • You need to provide -Credential parameter:

    Enter-PSSession –ComputerName Server –Credential Domain\UserName