Bewerken

Delen via


Get-AzOperationalInsightsLinkedStorageAccount

Get or list linked storage account

Syntax

Get-AzOperationalInsightsLinkedStorageAccount
   [-ResourceGroupName] <String>
   [-WorkspaceName] <String>
   [[-DataSourceType] <String>]
   [-DefaultProfile <IAzureContextContainer>]
   [<CommonParameters>]

Description

Get linked storage account, list all linked storage accounts when "-DataSourceType" was not specified

Examples

Example 1

Get-AzOperationalInsightsLinkedStorageAccount -ResourceGroupName "rg-name" -WorkspaceName "workspace-name"

Id                : /subscriptions/{subscription}/resourceGroups/{rg-name}/providers/Microsoft.OperationalInsights/workspaces/{workspace-name}/linkedStorageAccounts/customlogs
Name              :
Type              : Microsoft.OperationalInsights/workspaces/linkedStorageAccounts
DataSourceType    : CustomLogs
StorageAccountIds : {/subscriptions/{subscription}/resourceGroups/{rg-name}/providers/Microsoft.Storage/storageAccounts/{account}}

list linked storage accoounts for workspace {workspace-name}

Parameters

-DataSourceType

Data Source Type should be one of 'CustomLogs', 'AzureWatson'.

Type:String
Accepted values:CustomLogs, AzureWatson, Query, Alerts
Position:2
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with Azure.

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ResourceGroupName

The resource group name.

Type:String
Position:0
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-WorkspaceName

The workspace name.

Type:String
Position:1
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

Inputs

None

Outputs

PSLinkedStorageAccountsResource