PrepAway - Latest Free Exam Questions & Answers

Which Azure PowerShell cmdlet should you use with each PowerShell command line?

DRAG DROP
Your company manages several Azure Web Sites that are running in an existing webhosting plan named plan1.
You need to move one of the websites, named contoso, to a new web-hosting plan named plan2.
Which Azure PowerShell cmdlet should you use with each PowerShell command line? To
answer, drag the appropriate Azure PowerShell cmdlet to the correct location in the
PowerShell code. Each PowerShell cmdlet may be used once, more than once, or not at all.
You may need to drag the split bar between panes or scroll to view content.

PrepAway - Latest Free Exam Questions & Answers

Answer:

Explanation:

25 Comments on “Which Azure PowerShell cmdlet should you use with each PowerShell command line?

  1. CastorTray says:

    Example:
    The following command is actually a series of commands (delimited by semi-colons) that change the
    values of the properties in the $p variable.
    Windows PowerShell
    PS C:\> $p.siteMode = “Basic”; $p.sku = “Basic”; $p.computeMode = “Dedicated”; $p.serverFarm =
    “Default2”
    The next command uses the Set-AzureResource cmdlet to change the change the properties of the
    ContosoLabWeb2 web site. The value of the PropertyObject parameter is the $p variable that contains
    the Properties object and the new values. The command saves the output (the updated resource) in the
    $r2 variable.
    Windows PowerShell
    PS C:\> $r2 = Set-AzureResource -Name ContosoLabWeb2 -ResourceGroupName ContosoLabsRG
    -ResourceType “Microsoft.Web/sites” -ApiVersion 2004-04-01 -PropertyObject $p




    0



    0
  2. Nitin says:

    I gave exam in December, he question came on ARM model.
    Question will be similar but powershell commands will be

    PS C:\>$Resource = Get-AzureRmResource -ResourceType “microsoft.web/sites” -ResourceGroupName “ResourceGroup11” -ResourceName “ContosoSite”
    PS C:\> $Resource.Properties.Enabled = “False”
    PS C:\> $Resource | Set-AzureRmResource -Force




    0



    0

Leave a Reply