You recently created a new Azure subscription that contains a user named Admin1.
Admin1 attempts to deploy an Azure Marketplace resource by using an Azure Resource Manager template. Admin1 deploys the template by using Azure
PowerShell and receives the following error message: User failed validation to purchase resources. Error message: Legal terms have not been accepted for this item on this subscription. To accept legal terms, please go to the Azure portal (http://go.microsoft.com/fwlink/?LinkId=534873) and configure programmatic deployment for the Marketplace item or create it there for the first time.
You need to ensure that Admin1 can deploy the Marketplace resource successfully.
What should you do?
Click on the arrows to vote for the correct answer
A. B. C. D.C
https://docs.microsoft.com/en-us/powershell/module/az.marketplaceordering/set-azmarketplaceterms?view=azps-4.1.0The error message suggests that the user Admin1 needs to accept the legal terms for the Marketplace item before deploying it programmatically. Therefore, to resolve the issue and allow Admin1 to deploy the Marketplace resource successfully, we need to perform the following steps:
Step 1: Register the Microsoft.Marketplace resource provider To use a Marketplace item in Azure, we need to register the corresponding resource provider first. In this case, we need to register the Microsoft.Marketplace resource provider by following these steps:
Step 2: Accept the legal terms for the Marketplace item Once the Microsoft.Marketplace resource provider is registered, we can now accept the legal terms for the Marketplace item. To do this, we need to follow these steps:
Step 3: Deploy the Marketplace item using Azure PowerShell Now that the legal terms have been accepted for the Marketplace item, Admin1 can deploy it programmatically using Azure PowerShell. The deployment command should include the necessary parameters for the Marketplace item, such as the SKU and version.
So, the correct answer to the exam question is option C. From Azure PowerShell, run the Set-AzMarketplaceTerms cmdlet. This cmdlet allows us to accept the legal terms for a Marketplace item programmatically, which is what Admin1 needs to do before deploying the item. Option A (Set-AzApiManagementSubscription cmdlet) is not related to the issue at hand, as it is used for managing Azure API Management subscriptions. Option B (registering the Microsoft.Marketplace resource provider) is a necessary step, but it alone won't solve the problem. Option D (assigning the Billing administrator role to Admin1) is also not related to the issue, as it is used for managing billing for the subscription, not for deploying Marketplace items.