Azure-无法删除日志分析和解决方案

时间:2019-05-15 11:24:57

标签: azure azure-log-analytics

我正在尝试删除日志分析和解决方案,但是由于错误,我无法使用门户网站进行删除。已经确保没有任何东西可以引用日志分析(例外是解决方案)。

试图使用azure powershell进行此操作,但是我遇到了一些错误,我不知道我还能做些什么……我们没有支持计划,无法寻求技术帮助...

我尝试过的powershell脚本示例:

Remove-AzureRmResource -ResourceId "/subscriptions/bb7a9927-XXXX-XXXX-XXXX-XXXXXXXXXXXX/resourceGroups/uwe-azukw-rg-test-infrastructure/providers/microsoft.operationalinsights/workspaces/uwe-azuks-law-test-logAnalytics" -Force
Remove-AzureRmResource : Conflict : The workspace cannot be deleted because it's used by the following solution resources: /subscriptions/bb7a9927-XXXX-XXXX-XXXX-XXXXXXXXXXXX/resourceGroups/uwe-azukw-rg-test-infrastructure/providers/microsoft.operationalinsights/workspaces/uwe-azuks-law-test-logAnalytics/views/LogicAppsManagement(uwe-azuks-law-test-logAnalytics)
At line:1 char:1
+ Remove-AzureRmResource -ResourceId "/subscriptions/bb7a9927-703e-4045 ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : CloseError: (:) [Remove-AzureRmResource], ErrorResponseMessageException
    + FullyQualifiedErrorId : Conflict,Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation.RemoveAzureResourceCmdlet 

任何人都知道如何删除该视图?如果我尝试以下错误,但不确定如何更改值

PS C:\WINDOWS\system32> Remove-AzureRmResource -ResourceId "/subscriptions/bb7a9927-XXXX-XXXX-XXXX-XXXXXXXXXXXX/resourceGroups/uwe-azukw-rg-test-infrastructure/providers/microsoft.operationalinsights/workspaces/uwe-azuks-law-test-logAnalytics/views/LogicAppsManagement(uwe-azuks-law-test-logAnalytics)" -Force
Remove-AzureRmResource : NoRegisteredProviderFound : No registered resource provider found for location 'uksouth' and API version '2015-01-01' for type 'workspaces'. The supported api-versions are 
'2015-03-20, 2015-11-01-preview, 2017-01-01-preview, 2017-03-03-preview, 2017-03-15-preview, 2017-04-26-preview'. The supported locations are 'eastus, westeurope, southeastasia, australiasoutheast, 
westcentralus, japaneast, uksouth, centralindia, canadacentral, westus2, australiacentral, australiaeast, francecentral, koreacentral, northeurope, centralus, eastasia, eastus2, southcentralus, 
northcentralus, westus'.
At line:1 char:1
+ Remove-AzureRmResource -ResourceId "/subscriptions/bb7a9927-XXXX-XXXX ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : CloseError: (:) [Remove-AzureRmResource], ErrorResponseMessageException
    + FullyQualifiedErrorId : NoRegisteredProviderFound,Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation.RemoveAzureResourceCmdlet 

1 个答案:

答案 0 :(得分:0)

要删除工作空间,建议您使用cmdlet Remove-AzOperationalInsightsWorkspace / Remove-AzureRmOperationalInsightsWorkspace

要解决'NoRegisteredProviderFound'错误,您可能必须使用cmdlet Register-AzResourceProvider / Register-AzureRmResourceProvider注册提供程序。有关更多详细信息,请参阅this教程。

希望这会有所帮助!!干杯!