I am having a problem with an web application that connects to CRM. I was testing it on dev server and it would work fine but when I tried changing connectionStrings to connect to the production server, I am not able to access views that need db connection. The only difference between the two server is that dev server has crm and db on the same server whereas production server has one server just for its db. I think I might be missing some config information on my web.config.
I receive an error mentioning about SocketException, WebException and InvalidOperationException. The most interesting one to read is the invalidOperationException one as it says:
“Metadata contains a reference that cannot be resolved: 'http://xxx:5555/AESCRM/XRMServices/2011/Organization.svc?wsdl'.]”.The link given there is the actual sqlserver address and not the crmserver one, so I think the app is using the data-source given in connectionString to obtain organization service. At the moment I have info about the app under <appSettings>. In IIS, all those config are shown. Web.config
<add name="XXCRM_MSCRMEntities" connectionString="metadata=res://*/crm.csdl|res://*/crm.ssdl|res://*/crm.msl; provider=System.Data.SqlClient; provider connection string="data source=sqlserver;initial catalog=XXCRM_MSCRM;integrated security=True;MultipleActiveResultSets=True;App=EntityFramework"" providerName="System.Data.EntityClient" />
<add key="webpages:Version" value="126.96.36.199" />
<add key="webpages:Enabled" value="false" />
<add key="PreserveLoginUrl" value="true" />
<add key="ClientValidationEnabled" value="true" />
<add key="crmpassword" value="XXX" />
<add key="server" value="crmserver:5555/XXCRM" />
<add key="username" value="XXX" />
<add key="domain" value="XX" />
I could be many things.
can you ping the name of the sql server from the crm server machine?
you are using the port 5555. you are now on an distributed environment.
Do you have a firewall enabled between? try to temporarily shut down the firewalls or try to add a rule for port 5555
you may need to configure sql server and reporting server to accept remote connection.
You may try some app that would have the connection string wizard to validate. something like this:
Bruno Lucas, Senior CRM Consultant
DynamicDay CRM Blog
Please mark my post as "Verified" If it helped to solve your problem
Thanks for your reply.
The error was actually a mistake of mine. I was putting the sql server address instead of the crm one, so it wasn't able to find the organization and etc.
Sometimes we forget what happens behind the scenes and forget little config details like this hahah
It's all sorted,