There a number of settings within the DeploymentProperties table within the MSCRM_CONFIG database which sometimes we need to change. Microsoft recommend changing this via power shell with the following command:
add-pssnapin Microsoft.Crm.Powershell
To allow the saving of credentials when SSL is not used, we can run the following commands:
$itemSetting = new-object ‘System.Collections.Generic.KeyValuePair[String,Object]'("AllowCredentialsEntryViaInsecureChannels",1)
$configEntity = New-Object "Microsoft.Xrm.Sdk.Deployment.ConfigurationEntity"
$configEntity.LogicalName="Deployment"
$configEntity.Attributes = New-Object "Microsoft.Xrm.Sdk.Deployment.AttributeCollection"
$configEntity.Attributes.Add($itemSetting)
Set-CrmAdvancedSetting -Entity $configEntity
To allow the use of connections to servers that do not use SSL, we can run the following commands:
$itemSetting = new-object 'System.Collections.Generic.KeyValuePair[String,Object]'("ECAllowNonSSLEmail",1)
$configEntity = New-Object "Microsoft.Xrm.Sdk.Deployment.ConfigurationEntity"
$configEntity.LogicalName="Deployment"
$configEntity.Attributes = New-Object "Microsoft.Xrm.Sdk.Deployment.AttributeCollection"
$configEntity.Attributes.Add($itemSetting)
Set-CrmAdvancedSetting -Entity $configEntity
There are also a number of other settings across a CRM Deployment which we can change via PowerShell:
To Enable Tracing, we can run the following commands:
$setting = Get-CrmSetting TraceSettings
$setting.Enabled=$True
Set-CrmSetting $setting
Get-CrmSetting TraceSettings
CallStack : True
Categories : *:Error
Directory : c:\crmdrop\logs
Enabled : True
FileSize : 10
ExtensionData : System.Runtime.Serialization.ExtensionDataObject
To Disable Tracing, we can run the following commands:
$setting = Get-CrmSetting TraceSettings
$setting.Enabled=$False
Set-CrmSetting $setting
Get-CrmSetting TraceSettings
CallStack : True
Categories : *:Error
Directory : c:\crmdrop\logs
Enabled : False
FileSize : 10
ExtensionData : System.Runtime.Serialization.ExtensionDataObject
The following table shows some of the settings that can be changed via PowerShell.
Configuration settings class name | Description |
Contains settings values regarding asynchronous jobs and can be used to tune the asynchronous processing service. | |
Contains settings for claims authentication. | |
Contains settings that pertain to running custom code. | |
Contains settings for dashboards. | |
Contains settings that tune the operation of duplicate detection. | |
Contains settings for enterprise transaction management that can be used to throttle CRM for Outlook. | |
Contains settings for Internet facing deployments. | |
Contains settings that tune a data import operation. | |
Contains settings for the Marketplace. | |
Contains monitoring settings. | |
Contains settings for multi-entity quick find (finds records of different types). | |
Contains settings for quick find (finds records of one type). | |
Contains settings for controlling server side synchronizations for accounts, contacts and tasks. | |
Contains settings for controlling server side synchronizations for emails. | |
Contains settings for controlling server side synchronizations for queues. | |
Contains SQM settings. | |
Contains settings for auto created (system-managed) access teams. | |
Contains settings which can be used to throttle CRM for Outlook. | |
Contains settings that tune the amount of trace information generated. | |
Contains deployment root domain address values. | |
Contains deployment wide workflow settings. | |
Contains settings for Yammer. |
Note: A guide to using PowerShell with Dynamics CRM can be found on MSDN here which has a number of useful of cmdlets for administrating a Dynamics CRM Deployment, you can also see a list of all of the Advanced Settings that can be changed via PowerShell here.
This is a short tip but can be usefully if you want to quickly change a setting within a CRM 2013 Deployment.
@simonjen1