Uncategorized · March 20, 2021 0

Install .exe remotely with PowerShell &(PsExec)

Good day,

I will share with you today, how to install exe files remotely using PowerShell and the tool psexec.exe.

If you are unfamiliar with the difference between Psexec vs. PowerShell remoting read my other thread here

First of all, you need to copy the exe file to the remote computer; in my case I like to copy it to C:\temp\something.exe

From the local Computer launch ISE as administrator and use the code

$computerName = "something"
PsExec.exe -accepteula -s -high \$computerName "C:\temp\something.exe" /passive /quiet /norestart

As you see, I have used the Tool PsExec.exe and used the following keys:

-sRun the remote process in the System account.
-prioritySpecifies -low, -belownormal, -abovenormal, -high or -realtime to run the process at a different priority. Use -background to run at low memory and I/O priority on Vista.

if you would like to read more about PsExec.exe here is the link to Microsoft.

Thanks and wish you good day : )


Close Bitnami banner