正在尝试查找现有的IaaSDiagnostics on Scale集合,但无法将设置提取为字符串输出,
我试过了,但作为JProperty形式的返回值用处不大,
Get-AzureRmVmss -ResourceGroupName usptenant-DAT-EastUS -VMScaleSetName besfvm `
| Select-Object -ExpandProperty VirtualMachineProfile `
| Select-Object -ExpandProperty ExtensionProfile `
| %{ $_.Extensions[1] | Select-Object -ExpandProperty Settings }我坚持使用类型转换,或者在访问诊断信息时完全处于错误的方向。
发布于 2017-03-14 18:57:00
找到了使用Azure-Cli的方法
使用
az vmss extension show --name
--resource-group
--vmss-name并将输出导出到Json文件,请确保将文件输出的扩展名设置为Json,您将得到Base64编码的字符串。
编辑:
使用powerShell
(Get-AzureServiceAvailableExtension -ExtensionName 'PaaSDiagnostics' -ProviderNamespace 'Microsoft.Azure.Diagnostics').PublicConfigurationSchema | Out-File –Encoding utf8 -FilePath 'C:\temp\WadConfig.xsd'https://stackoverflow.com/questions/42781495
复制相似问题