1 Reply Latest reply on Aug 1, 2020 11:43 AM by LucD

    invoke-vmscript netsh command requires build-in administrator

    moorthyragav Lurker

      $netshDNS2 = "C:\windows\system32\netsh.exe interface ip add dns $NetworkAdapter $DNS2 index=2"

      Invoke-VMScript –VM $GuestVMname -guestuser $GuestUsername -guestpassword $GuestUserpwd -ScriptType bat -ScriptText $netshDNS2


      In the above script the -guestuser (user name) is the administrator privileged user(the user is in the local administrator Group).

      But i getting the error "the requested operation requires elevation (run as administrator)"

      we are not able to use build-in administrator account.

      Please help on the issue