How to take backup of azure vms parellelly using powershell script

Azure-learning 56 Reputation points
2022-07-13T12:35:48.237+00:00

How to take backup of azure vms parallelly in powershell script.

I have a script which is creating vault , taking the backup and checking the backup status until it is complete . It is reading vm info from a input csv file.

Input= "vmdata.csv"

$inputs = Import-Csv -Path $Input

foreach ($input in $inputs)  

`` {
"Code for backup
}

but it is doing sequentially , what is the best way in powershell script to do it parallelly .

Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,627 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Ryan McCallum 1 Reputation point Microsoft Employee
    2022-07-13T15:40:28.373+00:00

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.