Answered by:
Can't add users to CRM 2013

Question
-
I'm running on-premise CRM 2013; Installation started as CRM 4 and has been updated via CRM 2011 to CRM2013 Rollup 2. Adding users used to work, unfortunately I can't say at what point adding users stopped working as it'S quite a while that the last user had to be added.
Now trying to add a new user runs into an unexpected error. Any hint what I'm doing wrong would be appreciated.
Trace:
# CRM Tracing Version 2.0
# LocalTime: 2014-04-23 17:00:09.522
# Categories:
# CallStackOn: No
# ComputerName: CRM
# CRMVersion: 6.0.0002.0051
# DeploymentType: OnPremise
# ScaleGroup:
# ServerRole: AppServer, AsyncService, DiscoveryService, ApiServer, HelpServer, DeploymentService, SandboxServer, DeploymentManagementTools, VssWriter, EmailConnector
[2014-04-23 17:00:09.522] Process: w3wp |Organization:b4a96c60-8c49-e011-893a-00155d01111c |Thread: 27 |Category: Platform.Metadata |User: 00000000-0000-0000-0000-000000000000 |Level: Error |ReqId: ca917b2d-923c-4583-ae6a-caf2a172c328 | <>c__DisplayClass1.<LoadMetadataContainerFromDatabase>b__0 ilOffset = 0x14
>Multi-org sharable cache loading system and non-system metadata with build number 6.0.2.51 and language 1031
[2014-04-23 17:00:24.190] Process: w3wp |Organization:b4a96c60-8c49-e011-893a-00155d01111c |Thread: 31 |Category: Application |User: 00000000-0000-0000-0000-000000000000 |Level: Error |ReqId: cc09d70e-f3e1-4df7-876e-5fd9070e05e1 | SystemAlerts.GetAlertsLastAccessTime ilOffset = 0x3B
>Exception on getting the last alerts access time : Unhandled Exception: System.NullReferenceException: Der Objektverweis wurde nicht auf eine Objektinstanz festgelegt.
bei Microsoft.Crm.Application.WebServices.SystemAlerts.GetAlertsLastAccessTime()
[2014-04-23 17:01:20.767] Process: w3wp |Organization:b4a96c60-8c49-e011-893a-00155d01111c |Thread: 34 |Category: ADUtility |User: 534effb4-1901-4a19-94d9-e062b367f987 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | SecurityUtils.AddPrincipalToGroup ilOffset = 0x1A4
>Add user 42e59f9c-8f47-4415-9df6-7740455b6f80 to group 6384cb92-16db-4e99-8d5b-72a12945dc73 using Distinguished Named failed, trying again to add the user using SID.
[2014-04-23 17:01:21.970] Process: w3wp |Organization:b4a96c60-8c49-e011-893a-00155d01111c |Thread: 34 |Category: Platform.Sdk |User: 534effb4-1901-4a19-94d9-e062b367f987 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | VersionedPluginProxyStepBase.Execute ilOffset = 0x65
>Web Service Plug-in failed in SdkMessageProcessingStepId: {5ACABB1B-EA3E-DB11-86A7-000A3A5473E8}; EntityName: systemuser; Stage: 30; MessageName: Create; AssemblyName: Microsoft.Crm.Extensibility.InternalOperationPlugin, Microsoft.Crm.ObjectModel, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35; ClassName: Microsoft.Crm.Extensibility.InternalOperationPlugin; Exception: Unhandled Exception: System.Reflection.TargetInvocationException: Ein Aufrufziel hat einen Ausnahmefehler verursacht.
bei System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
bei System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
bei System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
bei System.Web.Services.Protocols.LogicalMethodInfo.Invoke(Object target, Object[] values)
bei Microsoft.Crm.Extensibility.InternalOperationPlugin.Execute(IServiceProvider serviceProvider)
bei Microsoft.Crm.Extensibility.V5PluginProxyStep.ExecuteInternal(PipelineExecutionContext context)
bei Microsoft.Crm.Extensibility.VersionedPluginProxyStepBase.Execute(PipelineExecutionContext context)
Inner Exception: System.Collections.Generic.KeyNotFoundException: Der angegebene Schlüssel war nicht im Wörterbuch angegeben.
bei Microsoft.Crm.ObjectModel.UserSettingsServiceInternal`1.PopulateOrgDefaults(IBusinessEntity entity, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.UserSettingsServiceInternal`1.Create(IBusinessEntity usersettings, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.CreateDefaultUserSettings(Guid userId, Guid businessId, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.CreateInternal(Guid organizationId, IBusinessEntity systemuser, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.Create(IBusinessEntity systemuser, ExecutionContext context)
.
[2014-04-23 17:01:22.517] Process: w3wp |Organization:b4a96c60-8c49-e011-893a-00155d01111c |Thread: 34 |Category: Exception |User: 534effb4-1901-4a19-94d9-e062b367f987 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | CrmException..ctor ilOffset = 0x7
at CrmException..ctor(String message, Exception innerException, Int32 errorCode, Boolean isFlowControlException) ilOffset = 0x7
at CrmException..ctor(Exception innerException, Int32 errorCode, Object[] arguments) ilOffset = 0xB
at VersionedPluginProxyStepBase.Execute(PipelineExecutionContext context) ilOffset = 0x65
at Pipeline.Execute(PipelineExecutionContext context) ilOffset = 0x65
at MessageProcessor.Execute(PipelineExecutionContext context) ilOffset = 0x1C5
at InternalMessageDispatcher.Execute(PipelineExecutionContext context) ilOffset = 0xE4
at ExternalMessageDispatcher.ExecuteInternal(IInProcessOrganizationServiceFactory serviceFactory, IPlatformMessageDispatcherFactory dispatcherFactory, String messageName, String requestName, Int32 primaryObjectTypeCode, Int32 secondaryObjectTypeCode, ParameterCollection fields, CorrelationToken correlationToken, CallerOriginToken originToken, UserAuth userAuth, Guid callerId, Guid transactionContextId, Int32 invocationSource, Nullable`1 requestId, Version endpointVersion) ilOffset = 0x16E
at OrganizationSdkServiceInternal.ExecuteRequest(OrganizationRequest request, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType, UserAuth userAuth, Guid targetUserId, Boolean traceRequest, OrganizationContext context, Boolean returnResponse) ilOffset = 0x16A
at OrganizationSdkServiceInternal.ExecuteRequest(OrganizationRequest request, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType) ilOffset = 0x3D
at OrganizationSdkServiceInternal.Execute(OrganizationRequest request, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType) ilOffset = 0x24
at InprocessServiceProxy.ExecuteCore(OrganizationRequest request) ilOffset = 0x34
at PlatformCommand.XrmExecuteInternal() ilOffset = 0xF6
at CreateCommand.Execute() ilOffset = 0xC
at EntityProxy.Create(Boolean performDuplicateCheck, Guid auditingTransactionId) ilOffset = 0x0
at EntityProxy.Create(Boolean performDuplicateCheck) ilOffset = 0x7
at SystemUser.Create(Boolean performDuplicateCheck) ilOffset = 0x1F
at EntityProxy.CreateAndRetrieve(String[] columnSet, Boolean performDuplicateCheck) ilOffset = 0x0
at CommandBase.UpdateEntity(Entity entity, Boolean retrieve) ilOffset = 0xA6
at SaveCommand.ExecuteCommand(String commandXml) ilOffset = 0xFB
at CommandBase.Execute(String commandXml) ilOffset = 0x13
at InlineEditWebService.Execute(Int32 command, String commandXml) ilOffset = 0xBE
at RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) ilOffset = 0xFFFFFFFF
at RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) ilOffset = 0x25
at RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) ilOffset = 0x89
at LogicalMethodInfo.Invoke(Object target, Object[] values) ilOffset = 0x4F
at WebServiceHandler.Invoke() ilOffset = 0xC3
at WebServiceHandler.CoreProcessRequest() ilOffset = 0x13E
at SyncSessionlessHandler.ProcessRequest(HttpContext context) ilOffset = 0x39
at HandlerWrapper.ProcessRequest(HttpContext context) ilOffset = 0x7
at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() ilOffset = 0x18D
at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) ilOffset = 0x15
at ApplicationStepManager.ResumeSteps(Exception error) ilOffset = 0x10A
at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData) ilOffset = 0x5C
at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr) ilOffset = 0x16A
at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType) ilOffset = 0x4B
>Crm Exception: Message: An unexpected error occurred., ErrorCode: -2147220970, InnerException: System.Collections.Generic.KeyNotFoundException: Der angegebene Schlüssel war nicht im Wörterbuch angegeben.
bei Microsoft.Crm.ObjectModel.UserSettingsServiceInternal`1.PopulateOrgDefaults(IBusinessEntity entity, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.UserSettingsServiceInternal`1.Create(IBusinessEntity usersettings, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.CreateDefaultUserSettings(Guid userId, Guid businessId, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.CreateInternal(Guid organizationId, IBusinessEntity systemuser, ExecutionContext context)
bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.Create(IBusinessEntity systemuser, ExecutionContext context)
[2014-04-23 17:01:22.517] Process: w3wp |Organization:b4a96c60-8c49-e011-893a-00155d01111c |Thread: 34 |Category: Platform |User: 534effb4-1901-4a19-94d9-e062b367f987 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | MessageProcessor.Execute ilOffset = 0x1C5
>MessageProcessor fail to process message 'Create' for 'systemuser'.
[2014-04-23 17:01:22.564] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread: 34 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | ExceptionConverter.ConvertToFault ilOffset = 0x69
>UNEXPECTED: no fault?
[2014-04-23 17:01:22.579] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread: 34 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | ExceptionConverter.ConvertMessageAndErrorCode ilOffset = 0x23B
>System.Collections.Generic.KeyNotFoundException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #08B39368: System.Collections.Generic.KeyNotFoundException: Der angegebene Schlüssel war nicht im Wörterbuch angegeben.
> bei Microsoft.Crm.ObjectModel.UserSettingsServiceInternal`1.PopulateOrgDefaults(IBusinessEntity entity, ExecutionContext context)
> bei Microsoft.Crm.ObjectModel.UserSettingsServiceInternal`1.Create(IBusinessEntity usersettings, ExecutionContext context)
> bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.CreateDefaultUserSettings(Guid userId, Guid businessId, ExecutionContext context)
> bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.CreateInternal(Guid organizationId, IBusinessEntity systemuser, ExecutionContext context)
> bei Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.Create(IBusinessEntity systemuser, ExecutionContext context)
[2014-04-23 17:01:22.595] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread: 34 |Category: Exception |User: 00000000-0000-0000-0000-000000000000 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | CrmException..ctor ilOffset = 0x7
at CrmException..ctor(String message, Exception innerException, Int32 errorCode, Boolean isFlowControlException) ilOffset = 0x7
at CrmException..ctor(String message, Int32 errorCode) ilOffset = 0x5
at PlatformCommand.CreateCrmExceptionFromServiceFault(FaultException`1 fe) ilOffset = 0x1B
at PlatformCommand.XrmExecuteInternal() ilOffset = 0xF6
at CreateCommand.Execute() ilOffset = 0xC
at EntityProxy.Create(Boolean performDuplicateCheck, Guid auditingTransactionId) ilOffset = 0x0
at EntityProxy.Create(Boolean performDuplicateCheck) ilOffset = 0x7
at SystemUser.Create(Boolean performDuplicateCheck) ilOffset = 0x1F
at EntityProxy.CreateAndRetrieve(String[] columnSet, Boolean performDuplicateCheck) ilOffset = 0x0
at CommandBase.UpdateEntity(Entity entity, Boolean retrieve) ilOffset = 0xA6
at SaveCommand.ExecuteCommand(String commandXml) ilOffset = 0xFB
at CommandBase.Execute(String commandXml) ilOffset = 0x13
at InlineEditWebService.Execute(Int32 command, String commandXml) ilOffset = 0xBE
at RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) ilOffset = 0xFFFFFFFF
at RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) ilOffset = 0x25
at RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) ilOffset = 0x89
at LogicalMethodInfo.Invoke(Object target, Object[] values) ilOffset = 0x4F
at WebServiceHandler.Invoke() ilOffset = 0xC3
at WebServiceHandler.CoreProcessRequest() ilOffset = 0x13E
at SyncSessionlessHandler.ProcessRequest(HttpContext context) ilOffset = 0x39
at HandlerWrapper.ProcessRequest(HttpContext context) ilOffset = 0x7
at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() ilOffset = 0x18D
at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) ilOffset = 0x15
at ApplicationStepManager.ResumeSteps(Exception error) ilOffset = 0x10A
at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData) ilOffset = 0x5C
at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr) ilOffset = 0x16A
at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType) ilOffset = 0x4B
>Crm Exception: Message: An unexpected error occurred., ErrorCode: -2147220970
[2014-04-23 17:01:22.611] Process: w3wp |Organization:b4a96c60-8c49-e011-893a-00155d01111c |Thread: 34 |Category: Application |User: 00000000-0000-0000-0000-000000000000 |Level: Error |ReqId: 6dbaa475-2d7f-4854-a5db-5571dbb03d8d | ErrorInformation.LogError ilOffset = 0x17
>MSCRM Error Report:
--------------------------------------------------------------------------------------------------------
Error: An unexpected error occurred.
Error Number: 0x80040216
Error Message: An unexpected error occurred.
Error Details: An unexpected error occurred.
Source File: Not available
Line Number: Not available
Request URL:
Stack Trace Info: [CrmException: An unexpected error occurred.]
bei Microsoft.Crm.Application.Platform.ServiceCommands.PlatformCommand.XrmExecuteInternal()
bei Microsoft.Crm.Application.Platform.ServiceCommands.CreateCommand.Execute()
bei Microsoft.Crm.Application.Platform.EntityProxy.Create(Boolean performDuplicateCheck, Guid auditingTransactionId)
bei Microsoft.Crm.Application.Platform.EntityProxy.Create(Boolean performDuplicateCheck)
bei Microsoft.Crm.Application.Platform.SystemUser.Create(Boolean performDuplicateCheck)
bei Microsoft.Crm.Application.Platform.EntityProxy.CreateAndRetrieve(String[] columnSet, Boolean performDuplicateCheck)
bei Microsoft.Crm.Application.WebServices.InlineEdit.CommandBase.UpdateEntity(Entity entity, Boolean retrieve)
bei Microsoft.Crm.Application.WebServices.InlineEdit.SaveCommand.ExecuteCommand(String commandXml)
bei Microsoft.Crm.Application.WebServices.InlineEdit.CommandBase.Execute(String commandXml)
Wednesday, April 23, 2014 3:06 PM
Answers
-
Adding the user to Groups does not seem to be the problem. The user actually was added to to the group, and changing AutoGroupManagementOff = 1 doesn't change the result.
Just found the solution in another Post: cant-create-new-system-user-mscrmwebservice-error?forum=crmdevelopment
Issue seems to be some fields in the organistation not beeing filled correctly when updateing from older versions. Changing the number format solved the issue.
Tuesday, May 6, 2014 11:58 AM
All replies
-
Hi
Make sure that the deployment administrator & the CRM admin that you are using has the required privileges for the CRM OU in Active Directory.
Please vote if you find my post helpful - Thanks
Thursday, April 24, 2014 5:56 AM -
I retried the operation as a domain admin, no change - so that doesn't seem to be the issue?
Friday, April 25, 2014 8:06 AM -
There is an error from AD ('Add user 42e59f9c-8f47-4415-9df6-7740455b6f80 to group 6384cb92-16db-4e99-8d5b-72a12945dc73 using Distinguished Named failed, trying again to add the user using SID'). By default, CRM will try adding users to AD groups. This is done using the account that's the identity of the CrmAppPool (not the user trying to add users), so check the AD permissions of that user.
However, you may have other AD or DNS issues, which are not related to permissions. Ideally these would be resolved, but an alternative is to set the AutoGroupManagementOff = 1 registry value to disable adding users to groups
Microsoft CRM MVP - http://mscrmuk.blogspot.com/ http://www.excitation.co.uk
Monday, April 28, 2014 9:22 AMModerator -
Adding the user to Groups does not seem to be the problem. The user actually was added to to the group, and changing AutoGroupManagementOff = 1 doesn't change the result.
Just found the solution in another Post: cant-create-new-system-user-mscrmwebservice-error?forum=crmdevelopment
Issue seems to be some fields in the organistation not beeing filled correctly when updateing from older versions. Changing the number format solved the issue.
Tuesday, May 6, 2014 11:58 AM