We have a single server development environment of Dynamics CRM 2011 with IFD + Claims Based Authentication setup.
Struggling to run the CrmSvcUtil command without getting the following 'Access is denied' error. We are running the util as an administrator, who is also a System Administrator in Dynamics CRM 2011.
Command we are running is:
CrmSvcUtil.exe /url:https://myorg.deepspace9.com:444/myorg/XRMServices/2011/Organization.svc /out:MyOutputFile.cs /username:"deepspace9\administrator" /password:password*1
And we end up getting the error:
CrmSvcUtil : CRM Service Utility [Version 5.0.9690.2165]
c 2011 Microsoft Corporation. All rights reserved.
CrmSvcUtil.exe Error: 0 : Exiting program with exit code 2 due to exception : System.ServiceModel.Security.SecurityAccessDeniedException: Access is denied.
Server stack trace:
at System.ServiceModel.Channels.ServiceChannel.ThrowIfFaultUnderstood(Message reply, MessageFault fault, String action, MessageVersion version, FaultConverter faultConverter)
at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Microsoft.Xrm.Sdk.IOrganizationService.Execute(OrganizationRequest request)
at Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy.ExecuteCore(OrganizationRequest request)
at Microsoft.Crm.Services.Utility.SdkMetadataProviderService.RetrieveEntities(IOrganizationService service)
at Microsoft.Crm.Services.Utility.SdkMetadataProviderService.Microsoft.Crm.Services.Utility.IMetadataProviderService.LoadMetadata()
at Microsoft.Crm.Services.Utility.CrmSvcUtil.Run()
at Microsoft.Crm.Services.Utility.CrmSvcUtil.Main(String[] args)
We've also tried running the instructions at: http://community.adxstudio.com/products/adxstudio-portals/developers-guide/knowledge-base/crmsvcutilexe/claims-based-authentication-workaround-for-sdk-ver/
Any ideas?
Managed to get it working. Followed the instructions at http://blog.thinketg.com/blog/ben-klopfer/strongly-typed-code-file-generation-with-crmsvcutilexe-for-crm-2011-ifd-configurations-code
I had to run HTML decoding to get rid of the HTML tags and I didn't bother creating the batch file - I just ran the command directly:
CrmSvcUtil.exe /metadataproviderservice:"MetadataProvider.IfdMetadataProviderService, MetadataProvider" /codecustomization:"Microsoft.Xrm.Client.CodeGeneration.CodeCustomization, Microsoft.Xrm.Client.CodeGeneration" /url:"https://myorg.deepspace9.com:444/XRMServices/2011/Organization.svc" /out:"outputOrganizationXrm.cs" /namespace:OrganizationXrm /serviceContextName:XrmServiceContext /serviceContextPrefix:Xrm /u:"deepspace9\administrator" /p:password*1
Related
A Windows Forms application using Contract SOAP to Acumatica works fine on a development machine.
soapClient.Login with exactly the same parameters on a production server (Windows 2008) crashes with an error message:
Error Message: An error occurred while making the HTTP request to https://XXX.acumatica.com/entity/Default/17.200.001. This could be due to the fact that the server certificate is not configured properly with HTTP.SYS in the HTTPS case. This could also be caused by a mismatch of the security binding between the client and the server.
Stack trace:
Server stack trace:
at System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebException(WebException webException, HttpWebRequest request, HttpAbortReason abortReason)
at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout)
at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)
at System.ServiceModel.Dispatcher.RequestChannelBinder.Request(Message message, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at AcmtIntegrator.AcumaticaWSDL.DefaultSoap.Login(String name, String password, String company, String branch, String locale)
at AcmtIntegrator.AcumaticaWSDL.DefaultSoapClient.Login(String name, String password, String company, String branch, String locale) in D:\C2019\AcumaticaIntegrator\AcumaticaIntegrator\Connected Services\AcumaticaWSDL\Reference.cs:line 49298
at AcmtIntegrator.frmExtractLists.LoopAction(String lcAction, String lcExtractType, Boolean& llSuccess) in D:\C2019\AcumaticaIntegrator\AcumaticaIntegrator\frmExtractLists.cs:line 134, Source: mscorlib, InnerException: The underlying connection was closed: An unexpected error occurred on a send.,
Two fix were changed to make it work:
WSDL service reference was replaced to point to the Acumatica production URL, and
Security protocol was set to TLS 1.2:
System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12;
Thanks to all who tried to help.
I am getting the following error when trying to register a plugin in CRM 2013:
Unhandled Exception:
System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: Assembly can not be loaded.
DETAIL
Server stack trace:
at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Microsoft.Xrm.Sdk.IOrganizationService.Create(Entity entity)
at Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy.CreateCore(Entity entity)
at PluginRegistrationTool.RegistrationHelper.RegisterPlugin(CrmOrganization org, CrmPlugin plugin)
at PluginRegistrationTool.PluginRegistrationForm.btnRegister_Click(Object sender, EventArgs e)
I think the problem is that you are using the older version for Microsoft.Xrm.Sdk, Version=5.0.0.0, you should use version 6. So download the latest SDK from the following link http://www.microsoft.com/en-ca/download/details.aspx?id=40321, replace your dll reference in the plugin project, rebuild and try to update the plugins.
solved
Actually it was dll file of custom workflow written in C# not plugin dll...
This exception was thrown because , i was registering it on disk. Later i tried it to register on database and it worked fine...
I suggest all of you to register your plugins on disk and workflows on database.
hope this will solve if anyone face this problem in future.
dlls are registered using plugin registration tool. you can find in link (download)
I am configuring MS Dynamics connector for synchronising MS CRM 2011 and MS AX 2012.
It has been working fine with some Entities, but I cannot get the Account to work.
I have enabled the Address during the configuration and I can sync Customer Services with their Adresses into CRM's account, but not the other way around.
I have enabled the tracing for the connector and here is the error I get:
12/17/2013 14:21:27: task 2a6bcf1c-d62a-4f5d-af04-a465d48eb61f is WaitingToRun
12/17/2013 14:21:27: task 2a6bcf1c-d62a-4f5d-af04-a465d48eb61f is Running
12/17/2013 14:21:27: RetryTask starts execution. This is RetryTask attempt 3.
VERBOSE TID:TP-33 [2013-12-17T15:21:27.6853306+01:00]: [Retry : Retry key : [999999999911, e3187a8a-2567-e311-9f44-0050569239ef]] has started to read.
VERBOSE TID:TP-33 [2013-12-17T15:21:27.6853306+01:00]: Making "Retrieve" request on entity "" with conditions "" to CRM.
WARNING TID:TP-50 [2013-12-17T15:21:30.9146341+01:00]: An unrecognized exception was thrown [mscorlib::0x80131501].
ERROR TID:TP-50 [2013-12-17T15:21:30.9146341+01:00]: [Account to Customer Service] has encountered an error while reading records. Processing will be aborted. Error text: A record level exception has occurred for record [999999999912, 10d0bb3d-2667-e311-9f44-0050569239ef]. Error text : Request Failed. See the Exception Log for details.
--- Exception Dump ---
Caught Exception: [Microsoft.Dynamics.Integration.Service.Tasks.RecordException] A record level exception has occurred for record [999999999912, 10d0bb3d-2667-e311-9f44-0050569239ef]. Error text : Request Failed. See the Exception Log for details.
Stack trace:
Inner Exception: [System.ServiceModel.FaultException`1[schemas.microsoft.com.dynamics._2008._01.documents.Fault.AifFault]] Request Failed. See the Exception Log for details.
Stack trace:
Server stack trace:
at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at ConnCustomerOrgService.create(ConnCustomerOrgServiceCreateRequest request)
at ConnCustomerOrgServiceClient.create(CallContext CallContext, AxdConnCustomerOrg ConnCustomerOrg)
at Microsoft.Dynamics.Integration.Adapters.AX2012.DynamicServiceObjectProviderBase.WriteObject(Object value)
at Microsoft.Dynamics.Integration.Service.Tasks.RecordWork.DoRecordWork(DbMap map, Object key, OperationType operationType, DateTime startTime, String loggingSourceName)
task Account to Customer Service log event : Warning ...
task 6ef94c7f-a5cf-46bc-8be6-93fb2f06dc80 retry at 12/17/2013 14:21:30.
task Account to Customer Service progress at 100% ...
How is it possible to solve it?
I have two servers (Server A and Server B) in one SharePoint 2010 farm. I am getting following error on SharePoint Dashboard page while using the custom PPS filter webpart on Dashboard.
I have used Microsoft PerformancePoint Services SDK sample as base and created a custom Rendered class to define in FilterEditor Class as
filter.RendererClassName = typeof(CustomFilter).AssemblyQualifiedName;
Critial Error:
0x0500 PerformancePoint Service PerformancePoint Services 4 Critical An unexpected error occurred. Error 20798. Exception details: System.ServiceModel.FaultException: An unknown error has occurred. If the problem persists contact an administrator. There may be additional information in the server application event log. Server stack trace: at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc) at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout) at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation) at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message) Exception rethrown at [0]:... c9c0a044-c18d-4374-ad6f-e99d2a2959cd
Critial Error:
PerformancePoint Services 4 Critical ... at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) at Microsoft.PerformancePoint.Scorecards.IBIMonitoringServiceApplication.GetFilterDependencies(RepositoryLocation filterLocation) at Microsoft.PerformancePoint.Scorecards.BIMonitoringServiceApplicationProxy.<>c_DisplayClassbb.b_ba(IBIMonitoringServiceApplication channel) at Microsoft.PerformancePoint.Scorecards.BIMonitoringServiceApplicationProxy.ExecuteOnChannel(CodeBlock codeBlock) c9c0a044-c18d-4374-ad6f-e99d2a2959cd
And finally:
PerformancePoint Services ef8z Critical An exception occurred while rendering a Web control. The following diagnostic information might help to determine the cause of this problem: Microsoft.PerformancePoint.Scorecards.BpmException: There was a problem preparing the WebPart for display. PerformancePoint Services error code 20700. c9c0a044-c18d-4374-ad6f-e99d2a2959cd
Please advice what I should do to overcome this problem.
In the web.config file, how did you specifiy the assembly for the renderer? It should be in this format:
Namespace.Class name, DLL name, DLL version number, DLL culture, DLL public key token
And it should look something like the RendererClass in this example:
<CustomFCO type="Filter" subType="SampleFilter">
<Resources FCOName="Custom Filter" FCODescription="This is my custom filter." />
<RendererClass name="Microsoft.PerformancePoint.Scorecards.ServerRendering.MultiSelectTreeViewControl,
Microsoft.PerformancePoint.Scorecards.ServerRendering, Version=14.0.0.0,
Culture=neutral, PublicKeyToken=71e9bce111e9429c" />
<EditorURI uri="/_layouts/SampleFilterEditor.aspx" />
</CustomFCO>
(http://msdn.microsoft.com/en-us/library/ee556434.aspx)
I am trying to do a server side doc/docx to pdf conversion using Word Automation Services. I am using the basic sample from MSDN, Link: http://msdn.microsoft.com/en-us/library/ff742315.aspx and encounter an obscure error every time ConversionJob's Start() method is called. Here's the exception;
Source: mscorlib
Message: An unsecured or incorrectly secured fault was received from the other party. See the inner FaultException for the fault code and detail.
InnerException: System.ServiceModel.FaultException: An error occurred when verifying security for the message.
StackTrace: Server stack trace: at System.ServiceModel.Channels.SecurityChannelFactory1.SecurityRequestChannel.ProcessReply(Message reply, SecurityProtocolCorrelationState correlationState, TimeSpan timeout) at System.ServiceModel.Channels.SecurityChannelFactory1.SecurityRequestChannel.Request(Message message, TimeSpan timeout) at System.ServiceModel.Dispatcher.RequestChannelBinder.Request(Message message, TimeSpan timeout) at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout) at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation) at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message) Exception rethrown at [0]: at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) at Microsoft.IdentityModel.Protocols.WSTrust.IWSTrustContract.Issue(Message message) at Microsoft.IdentityModel.Protocols.WSTrust.WSTrustChannel.Issue(RequestSecurityToken rst, RequestSecurityTokenResponse& rstr) at Microsoft.IdentityModel.Protocols.WSTrust.WSTrustChannel.Issue(RequestSecurityToken rst) at Microsoft.SharePoint.SPSecurityContext.SecurityTokenForContext(Uri context, Boolean bearerToken, SecurityToken onBehalfOf, SecurityToken actAs, SecurityToken delegateTo) at Microsoft.SharePoint.SPSecurityContext.<>c_DisplayClass7.b_6() at Microsoft.SharePoint.Utilities.SecurityContext.RunAsProcess(CodeToRunElevated secureCode) at Microsoft.SharePoint.SPSecurityContext.GetProcessSecurityTokenForServiceContext() at Microsoft.SharePoint.SPSecurityContext.SecurityTokenForServiceContext(Uri contextUri) at Microsoft.SharePoint.SPChannelFactoryOperations.InternalCreateChannelActingAsLoggedOnUser[TChannel](ChannelFactory1 factory, EndpointAddress address, Uri via) at Microsoft.SharePoint.SPChannelFactoryOperations.CreateChannelActingAsLoggedOnUser[TChannel](ChannelFactory1 factory, EndpointAddress address) at Microsoft.Office.Word.Server.Service.ConfigChannelFactory1.CreateChannel() at Microsoft.Office.Word.Server.Service.WordServiceApplicationProxy.AddJob(Ucid ucid, Nullable1 subscriptionId, SPUserToken userToken, ConversionJobSettings settings, String name) at Microsoft.Office.Word.Server.Conversions.ConversionJob.Start() at VisualWebPartProject1.VisualWebPart1.VisualWebPart1UserControl.Page_Load(Object sender, EventArgs e)
I tried the same code inside one of our sharepoint sites, still got the same error. Trying this inside a Wcf Service has same result. I made a visual web part for this and same error. Changing user accounts or RunWithElevatedPrivileges didn't help either.
Since the sample requires Microsoft.Sharepoint and Microsoft.Office.Word.Server.Conversions namespaces, I have to run this code on some server having sharepoint installed. So IMHO, the time skew issue is not related as the code is ran over the same server where Word Automation Services are present. I expect some configuration problems on the sharepoint server side, but I don’t know what to check.
Let me know if any other details are required, thanks.
Without having more specifics around the code you're running it's hard to say. Take a look at the overall Word Automation Services content in the SDK.
Also, check out the topics under "Configuring Word Automation Services for Development" in the SDK in particular.