An Azure service that is used to provision Windows and Linux virtual machines.
Hello @汶徽 何 ,
In additional to TP, This error indicates that your ARM/Bicep template defines a required parameter named subnetId, but no value was supplied during deployment.
The subnetId parameter must contain the fully qualified Azure resource ID of the subnet into which the virtual machine’s network interface will be deployed. When provisioning a VM, Azure requires explicit network placement information so it can associate the VM’s NIC with the correct virtual network and subnet.
A valid subnet resource ID follows this format: /subscriptions/<subscriptionId>/resourceGroups/<rgName>/providers/Microsoft.Network/virtualNetworks/<vnetName>/subnets/<subnetName>
Get your subnet id-
az network vnet subnet show \
--resource-group <rgName> \
--vnet-name <vnetName> \
--name <subnetName> \
--query id -o tsv
Add it to your parameters file-
{ "parameters": { "subnetId": { "value": "/subscriptions/xxxx/resourceGroups/xxxx/providers/Microsoft.Network/virtualNetworks/MyVnet/subnets/MySubnet" } } }
Please let us know if you require any further assistance. I’d be happy to help. Thank you!