New-AzDataCollectionRuleAssociation
Buat asosiasi.
Sintaks
New-AzDataCollectionRuleAssociation
-AssociationName <String>
-ResourceUri <String>
[-DataCollectionEndpointId <String>]
[-DataCollectionRuleId <String>]
[-Description <String>]
[-DefaultProfile <PSObject>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
New-AzDataCollectionRuleAssociation
-AssociationName <String>
-ResourceUri <String>
-JsonFilePath <String>
[-DefaultProfile <PSObject>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
New-AzDataCollectionRuleAssociation
-AssociationName <String>
-ResourceUri <String>
-JsonString <String>
[-DefaultProfile <PSObject>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Deskripsi
Buat asosiasi.
Contoh
Contoh 1: Membuat asosiasi aturan pengumpulan data dengan aturan pengumpulan data tertentu
New-AzDataCollectionRuleAssociation -AssociationName myCollectionRule2-association1 -ResourceUri /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourcegroups/amcs-test/providers/microsoft.compute/virtualmachines/monitortestvm01 -DataCollectionRuleId /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/AMCS-TEST/providers/Microsoft.Insights/dataCollectionRules/myCollectionRule2
DataCollectionEndpointId :
DataCollectionRuleId : /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/AMCS-TEST/providers/Microsoft.Insights/dataCollectionRules/myCollectionRule2
Description :
Etag : "20017ecf-0000-0100-0000-651147350000"
Id : /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/amcs-test/providers/microsoft.compute/virtualmachines/monitortestvm01/providers/Microsof
t.Insights/dataCollectionRuleAssociations/myCollectionRule2-association1
MetadataProvisionedBy :
MetadataProvisionedByResourceId :
Name : myCollectionRule2-association1
ProvisioningState :
ResourceGroupName : amcs-test
SystemDataCreatedAt : 9/25/2023 8:39:15 AM
SystemDataCreatedBy : v-jiaji@microsoft.com
SystemDataCreatedByType : User
SystemDataLastModifiedAt : 9/25/2023 8:39:15 AM
SystemDataLastModifiedBy : v-jiaji@microsoft.com
SystemDataLastModifiedByType : User
Type : Microsoft.Insights/dataCollectionRuleAssociations
Perintah ini membuat asosiasi aturan pengumpulan data dengan aturan pengumpulan data tertentu.
Contoh 2: Membuat asosiasi titik akhir pengumpulan data dengan titik akhir pengumpulan data tertentu
New-AzDataCollectionRuleAssociation -AssociationName configurationAccessEndpoint -ResourceUri /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourcegroups/amcs-test/providers/microsoft.compute/virtualmachines/monitortestvm01 -DataCollectionEndpointId /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/AMCS-TEST/providers/Microsoft.Insights/dataCollectionEndpoints/myCollectionEndpoint
DataCollectionEndpointId : /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/AMCS-TEST/providers/Microsoft.Insights/dataCollectionEndpoints/myCollectionEndpoint
DataCollectionRuleId :
Description :
Etag : "21017484-0000-0100-0000-6511505c0000"
Id : /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/amcs-test/providers/microsoft.compute/virtualmachines/monitortestvm01/providers/Microsof
t.Insights/dataCollectionRuleAssociations/configurationAccessEndpoint
MetadataProvisionedBy :
MetadataProvisionedByResourceId :
Name : configurationAccessEndpoint
ProvisioningState :
ResourceGroupName : amcs-test
SystemDataCreatedAt : 9/25/2023 9:18:20 AM
SystemDataCreatedBy : v-jiaji@microsoft.com
SystemDataCreatedByType : User
SystemDataLastModifiedAt : 9/25/2023 9:18:20 AM
SystemDataLastModifiedBy : v-jiaji@microsoft.com
SystemDataLastModifiedByType : User
Type : Microsoft.Insights/dataCollectionRuleAssociations
Perintah ini membuat asosiasi titik akhir pengumpulan data tertentu dengan titik akhir pengumpulan data tertentu.
Parameter
-AssociationName
Nama asosiasi. Nama tidak peka huruf besar/kecil.
Jenis: | String |
Alias: | Name |
Position: | Named |
Nilai default: | None |
Diperlukan: | True |
Terima input alur: | False |
Terima karakter wildcard: | False |
-Confirm
Meminta Anda mengonfirmasi sebelum menjalankan cmdlet.
Jenis: | SwitchParameter |
Alias: | cf |
Position: | Named |
Nilai default: | None |
Diperlukan: | False |
Terima input alur: | False |
Terima karakter wildcard: | False |
-DataCollectionEndpointId
ID sumber daya titik akhir pengumpulan data yang akan dikaitkan.
Jenis: | String |
Position: | Named |
Nilai default: | None |
Diperlukan: | False |
Terima input alur: | False |
Terima karakter wildcard: | False |
-DataCollectionRuleId
ID sumber daya aturan pengumpulan data yang akan dikaitkan.
Jenis: | String |
Alias: | RuleId |
Position: | Named |
Nilai default: | None |
Diperlukan: | False |
Terima input alur: | False |
Terima karakter wildcard: | False |
-DefaultProfile
Parameter DefaultProfile tidak berfungsi. Gunakan parameter SubscriptionId saat tersedia jika menjalankan cmdlet terhadap langganan yang berbeda.
Jenis: | PSObject |
Alias: | AzureRMContext, AzureCredential |
Position: | Named |
Nilai default: | None |
Diperlukan: | False |
Terima input alur: | False |
Terima karakter wildcard: | False |
-Description
Deskripsi asosiasi.
Jenis: | String |
Position: | Named |
Nilai default: | None |
Diperlukan: | False |
Terima input alur: | False |
Terima karakter wildcard: | False |
-JsonFilePath
Jalur file Json yang disediakan ke operasi Buat
Jenis: | String |
Position: | Named |
Nilai default: | None |
Diperlukan: | True |
Terima input alur: | False |
Terima karakter wildcard: | False |
-JsonString
String Json yang disediakan ke operasi Buat
Jenis: | String |
Position: | Named |
Nilai default: | None |
Diperlukan: | True |
Terima input alur: | False |
Terima karakter wildcard: | False |
-ResourceUri
Pengidentifikasi sumber daya.
Jenis: | String |
Alias: | TargetResourceId |
Position: | Named |
Nilai default: | None |
Diperlukan: | True |
Terima input alur: | False |
Terima karakter wildcard: | False |
-WhatIf
Menunjukkan apa yang akan terjadi jika cmdlet berjalan. Cmdlet tidak dijalankan.
Jenis: | SwitchParameter |
Alias: | wi |
Position: | Named |
Nilai default: | None |
Diperlukan: | False |
Terima input alur: | False |
Terima karakter wildcard: | False |
Output
Azure PowerShell