Run Powershell script as Local System with psexec

psexec -i -s powershell.exe -ExecutionPolicy Unrestricted scriptname.ps1

x86 process on 64 bit OS :
psexec -i -s C:\Windows\syswow64\Windowspowershell\v1.0\powershell.exe -ExecutionPolicy Unrestricted scriptname.ps1

Leave a Comment