Powershell parallel jobs output file
问题 I have already done a lot of research, but still can't figure out how to accomplish what I want to do. I want to perform the same tasks parallel on 100 Linux servers. Here is a simplified example of my script: $computer=Get-Content "serverList.txt" $jobArray=@() $script={ $cpuThresh=70 $cpuUsage=<Get CPU usage of the host> Write-Host "CPU Usage: $cpuUsage %" if ($cpuUsage -ge $cpuThresh) { Write-Host "Unexpected CPU Usage" -ForegroundColor Red } } foreach ($system in $computer) { $jobArray +=