When i run PS script (robocopy cmd) on remote machine using invoke-command as job, it throws login error. The account i am running has admin privileges and when i run the same command onthe remote machine, it works fine.
Invoke-Command -session $servers -FilePath D:\script.ps1
Error 2016/10/04 10:39:00 ERROR 64 (0x00000040) Accessing Source Directory The specified network name is no longer available.
My question is what login does the script use when i run it from remote server ?
I found the issue, its a problem with multihop authentication.
Thanks everyone.
User contributions licensed under CC BY-SA 3.0