【发布时间】:2019-01-14 17:35:06
【问题描述】:
我正在尝试使用我的 ARM 代码构建多个 SQL VM。但是,我在创建网络对等互连时遇到了以下错误。
[ERROR] New-AzureRmResourceGroupDeployment : 08:40:20 - Error: Code=InvalidTemplate;
[ERROR] Message=Deployment template validation failed: 'The template resource
[ERROR] 'DI_SQLSERVER_VNETag5w7jqj6vp3a_TO_DI_DT_VN' for type
[ERROR] 'Microsoft.Network/virtualNetworks/virtualNetworkPeerings' at line '488' and
[ERROR] column '9' has incorrect segment lengths. A nested resource type must have
[ERROR] identical number of segments as its resource name. A root resource type must
[ERROR] have segment length one greater than its resource name. Please see
[ERROR] https://aka.ms/arm-template/#resources for usage details.'.
[ERROR]
[ERROR] At line:35 char:1
[ERROR] + New-AzureRmResourceGroupDeployment -ResourceGroupName $presourcegroup ...
[ERROR] + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[ERROR] + CategoryInfo : NotSpecified: (:) [New-AzureRmResourceGroupDeplo
[ERROR] yment], Exception
[ERROR] + FullyQualifiedErrorId : Microsoft.Azure.Commands.ResourceManager.Cmdlets
[ERROR] .Implementation.NewAzureResourceGroupDeploymentCmdlet
[ERROR]
[ERROR] New-AzureRmResourceGroupDeployment : The deployment validation failed
[ERROR] At line:35 char:1
[ERROR] + New-AzureRmResourceGroupDeployment -ResourceGroupName $presourcegroup ...
[ERROR] + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[ERROR] + CategoryInfo : CloseError: (:) [New-AzureRmResourceGroupDeploym
[ERROR] ent], InvalidOperationException
[ERROR] + FullyQualifiedErrorId : Microsoft.Azure.Commands.ResourceManager.Cmdlets
[ERROR] .Implementation.NewAzureResourceGroupDeploymentCmdlet
[ERROR]
请参阅下面的链接以获取代码。希望有人能对以下 arm 模板错误有所了解。
https://drive.google.com/open?id=1Iltf_Qlg9GLPmOKTVDpP2KjrQcLvVZDg
谢谢
【问题讨论】:
标签: azure-resource-manager azure-template