PowerShell Install software remotely.

Опубликовано: 20 Август 2020
на канале: Mr Automation
6,622
109

In this video, I demonstrate how to use multitasking and threading in PowerShell to optimize performance by distributing the CPU load and running processes simultaneously. Discover how to remotely install software on multiple servers at once, making system management more efficient.

Another video on multithreading :    • PowerShell - Install Software Remotely  

*powershell install software on remote computer
*How to Install software remotely on servers with powershell
*install software package with powershell
*install software with powershell
*how to start a remote process with powershell
*install software remotely on as many servers as you like
(How to install software simultaniously and remote with powershell)
*install software package with powershell
*install software with powershell
*How to install software remotely with powershell
*install software remotely on as many servers as you like simultaniously
*how to start a remote process with powershell
*invoke-command
*get-credential
*start-process
*get-content
*invoke-webrequest
*invoke-command
*get-credential
*start-process
*powershell remoting

Code:
#content server.txt would be: for every server 1 line with the server name in server.txt

$CWD = Split-Path $MyInvocation.MyCommand.Definition
$servers = get-content $CWD\server.txt
$domaincreds = Get-Credential

foreach($server in $servers){
Invoke-Command -ComputerName $server -ScriptBlock {
$URL = "https://www.7-zip.org/a/7z1900-x64.exe"
$outfile = "C:\Windows\Temp\7z1900-x64.exe"
Invoke-WebRequest -Uri $URL -Method Get -OutFile $outfile
Start-Process -FilePath $outfile -ArgumentList "/S" -Wait
} -Credential $domaincreds
}


Смотрите видео PowerShell Install software remotely. онлайн, длительностью часов минут секунд в хорошем качестве, которое загружено на канал Mr Automation 20 Август 2020. Делитесь ссылкой на видео в социальных сетях, чтобы ваши подписчики и друзья так же посмотрели это видео. Данный видеоклип посмотрели 6,622 раз и оно понравилось 109 посетителям.