< Back
Set-AzureServiceDiagnosticsExtension
Post
NAME Set-AzureServiceDiagnosticsExtension
SYNOPSIS
Enables Azure Diagnostics extension on specified roles or all roles on a deployed service or at deployment.
SYNTAX
Set-AzureServiceDiagnosticsExtension [[-ServiceName] <String>] [[-Slot] <String>] [[-Version] <String>] [[-ExtensionId] <String>] [[-Role] <String[]>]
[[-X509Certificate] <X509Certificate2>] [[-ThumbprintAlgorithm] <String>] [[-StorageAccountName] <String>] [[-StorageAccountKey] <String>]
[[-StorageAccountEndpoint] <String>] [[-StorageContext] <AzureStorageContext>] [-DiagnosticsConfigurationPath] <String> [-Profile <AzureSMProfile>]
[-InformationAction <ActionPreference>] [-InformationVariable <String>] [<CommonParameters>]
Set-AzureServiceDiagnosticsExtension [[-ServiceName] <String>] [[-Slot] <String>] [[-Version] <String>] [[-ExtensionId] <String>] [[-Role] <String[]>]
[[-CertificateThumbprint] <String>] [[-ThumbprintAlgorithm] <String>] [[-StorageAccountName] <String>] [[-StorageAccountKey] <String>]
[[-StorageAccountEndpoint] <String>] [[-StorageContext] <AzureStorageContext>] [-DiagnosticsConfigurationPath] <String> [-Profile <AzureSMProfile>]
[-InformationAction <ActionPreference>] [-InformationVariable <String>] [<CommonParameters>]
Set-AzureServiceDiagnosticsExtension [[-ServiceName] <String>] [[-Slot] <String>] [-DiagnosticsConfiguration] <ExtensionConfigurationInput[]> [-Profile
<AzureSMProfile>] [-InformationAction <ActionPreference>] [-InformationVariable <String>] [<CommonParameters>]
DESCRIPTION
The Set-AzureServiceDiagnosticsExtension cmdlet enables Azure Diagnostics extension on specified roles or all roles on a deployed service or at
deployment.
PARAMETERS
-ServiceName <String>
Specifies the Azure service name of the deployment.
Required? false
Position? 0
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Slot <String>
Specifies the environment of the deployment to modify. The acceptable values for this parameter are: Production or Staging.
Required? false
Position? 1
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Role <String[]>
Specifies an optional array of roles for which to specify the Azure Diagnostics configuration. If you do not specify this parameter, the diagnostics
configuration is applied as the default configuration for all roles.
Required? false
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-X509Certificate <X509Certificate2>
Specifies an X.509 certificate that, when specified, is automatically uploaded to the cloud service and used for encrypting the extension private
configuration.
Required? false
Position? 3
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ThumbprintAlgorithm <String>
Specifies a thumbprint hashing algorithm that is used with the thumbprint to identify the certificate. This parameter is optional and the default is
sha1.
Required? false
Position? 4
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageAccountName <String>
Required? false
Position? 5
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageAccountKey <String>
Required? false
Position? 6
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageAccountEndpoint <String>
Required? false
Position? 7
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageContext <AzureStorageContext>
Specifies an Azure storage context.
Required? false
Position? 8
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-DiagnosticsConfigurationPath <String>
Specifies the configuration for Azure Diagnostics. You can download the schema by using the following command:
(Get-AzureServiceAvailableExtension -ExtensionName 'PaaSDiagnostics' -ProviderNamespace 'Microsoft.Azure.Diagnostics').PublicConfigurationSchema |
Out-File -Encoding utf8 -FilePath 'WadConfig.xsd'
Required? true
Position? 9
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Version <String>
Specifies the version of the extension.
Required? false
Position? 10
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ExtensionId <String>
Required? false
Position? 11
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Profile <AzureSMProfile>
Specifies the Azure profile from which this cmdlet reads. If you do not specify a profile, this cmdlet reads from the local default profile.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-InformationAction <ActionPreference>
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-InformationVariable <String>
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-CertificateThumbprint <String>
Specifies a certificate thumbprint to use to encrypt the private configuration. This certificate has to already exist in the certificate store. If
you do not specify a certificate, this cmdlet creates a certificate.
Required? false
Position? 3
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-DiagnosticsConfiguration <ExtensionConfigurationInput[]>
Required? true
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
-------------------------- Example 1: Enable Azure Diagnostics extension --------------------------
PS C:\\>Set-AzureServiceDiagnosticsExtension -ServiceName $Svc -StorageContext $StorageContext -DiagnosticsConfigurationPath $WadConfigXML
This command enables the Azure Diagnostics extension for all roles.
-------------------------- Example 2: Enable Azure Diagnostics extension for a specified role --------------------------
PS C:\\>Set-AzureServiceDiagnosticsExtension -ServiceName $Svc -StorageContext $StorageContext -DiagnosticsConfigurationPath $WadConfigXML -Role
"WebRole01"
This command enables the Azure Diagnostics extension for a specified role.
RELATED LINKS
Get-AzureServiceDiagnosticsExtension
Remove-AzureServiceDiagnosticsExtension
SYNOPSIS
Enables Azure Diagnostics extension on specified roles or all roles on a deployed service or at deployment.
SYNTAX
Set-AzureServiceDiagnosticsExtension [[-ServiceName] <String>] [[-Slot] <String>] [[-Version] <String>] [[-ExtensionId] <String>] [[-Role] <String[]>]
[[-X509Certificate] <X509Certificate2>] [[-ThumbprintAlgorithm] <String>] [[-StorageAccountName] <String>] [[-StorageAccountKey] <String>]
[[-StorageAccountEndpoint] <String>] [[-StorageContext] <AzureStorageContext>] [-DiagnosticsConfigurationPath] <String> [-Profile <AzureSMProfile>]
[-InformationAction <ActionPreference>] [-InformationVariable <String>] [<CommonParameters>]
Set-AzureServiceDiagnosticsExtension [[-ServiceName] <String>] [[-Slot] <String>] [[-Version] <String>] [[-ExtensionId] <String>] [[-Role] <String[]>]
[[-CertificateThumbprint] <String>] [[-ThumbprintAlgorithm] <String>] [[-StorageAccountName] <String>] [[-StorageAccountKey] <String>]
[[-StorageAccountEndpoint] <String>] [[-StorageContext] <AzureStorageContext>] [-DiagnosticsConfigurationPath] <String> [-Profile <AzureSMProfile>]
[-InformationAction <ActionPreference>] [-InformationVariable <String>] [<CommonParameters>]
Set-AzureServiceDiagnosticsExtension [[-ServiceName] <String>] [[-Slot] <String>] [-DiagnosticsConfiguration] <ExtensionConfigurationInput[]> [-Profile
<AzureSMProfile>] [-InformationAction <ActionPreference>] [-InformationVariable <String>] [<CommonParameters>]
DESCRIPTION
The Set-AzureServiceDiagnosticsExtension cmdlet enables Azure Diagnostics extension on specified roles or all roles on a deployed service or at
deployment.
PARAMETERS
-ServiceName <String>
Specifies the Azure service name of the deployment.
Required? false
Position? 0
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Slot <String>
Specifies the environment of the deployment to modify. The acceptable values for this parameter are: Production or Staging.
Required? false
Position? 1
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Role <String[]>
Specifies an optional array of roles for which to specify the Azure Diagnostics configuration. If you do not specify this parameter, the diagnostics
configuration is applied as the default configuration for all roles.
Required? false
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-X509Certificate <X509Certificate2>
Specifies an X.509 certificate that, when specified, is automatically uploaded to the cloud service and used for encrypting the extension private
configuration.
Required? false
Position? 3
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ThumbprintAlgorithm <String>
Specifies a thumbprint hashing algorithm that is used with the thumbprint to identify the certificate. This parameter is optional and the default is
sha1.
Required? false
Position? 4
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageAccountName <String>
Required? false
Position? 5
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageAccountKey <String>
Required? false
Position? 6
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageAccountEndpoint <String>
Required? false
Position? 7
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-StorageContext <AzureStorageContext>
Specifies an Azure storage context.
Required? false
Position? 8
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-DiagnosticsConfigurationPath <String>
Specifies the configuration for Azure Diagnostics. You can download the schema by using the following command:
(Get-AzureServiceAvailableExtension -ExtensionName 'PaaSDiagnostics' -ProviderNamespace 'Microsoft.Azure.Diagnostics').PublicConfigurationSchema |
Out-File -Encoding utf8 -FilePath 'WadConfig.xsd'
Required? true
Position? 9
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Version <String>
Specifies the version of the extension.
Required? false
Position? 10
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-ExtensionId <String>
Required? false
Position? 11
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Profile <AzureSMProfile>
Specifies the Azure profile from which this cmdlet reads. If you do not specify a profile, this cmdlet reads from the local default profile.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-InformationAction <ActionPreference>
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-InformationVariable <String>
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-CertificateThumbprint <String>
Specifies a certificate thumbprint to use to encrypt the private configuration. This certificate has to already exist in the certificate store. If
you do not specify a certificate, this cmdlet creates a certificate.
Required? false
Position? 3
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-DiagnosticsConfiguration <ExtensionConfigurationInput[]>
Required? true
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
-------------------------- Example 1: Enable Azure Diagnostics extension --------------------------
PS C:\\>Set-AzureServiceDiagnosticsExtension -ServiceName $Svc -StorageContext $StorageContext -DiagnosticsConfigurationPath $WadConfigXML
This command enables the Azure Diagnostics extension for all roles.
-------------------------- Example 2: Enable Azure Diagnostics extension for a specified role --------------------------
PS C:\\>Set-AzureServiceDiagnosticsExtension -ServiceName $Svc -StorageContext $StorageContext -DiagnosticsConfigurationPath $WadConfigXML -Role
"WebRole01"
This command enables the Azure Diagnostics extension for a specified role.
RELATED LINKS
Get-AzureServiceDiagnosticsExtension
Remove-AzureServiceDiagnosticsExtension