CRM2011/2016 – Timeout problem when open Sharepoint documents from CRM

Today I had a big problem with our new customer: When they tried to open a document from CRM, they had an error:

a

After check a little bit, I found a timeout error on sharepoint.  The problem was the Cookie life time configuration:

[..]When using FBA or a trusted provider, SharePoint will set a cookie on the client called FedAuth. I’ll not go into the details of what’s inside the FedAuth cookie. Of course, the FedAuth cookie will have by default a certain lifetime. Session cookies can be configured too making the cookie invalid after the closing the browser and then bypassing the value in this settings.

The default value is 5 days.[..] (Microsoft text)

cp1

To resolve the problem I found this script:

$sts = Get-SPSecurityTokenServiceConfig
$sts.CookieLifetime = New-TimeSpan -Hours 7
$sts.Update()

At the end I restart IIS and all is run in right way.

Unable to activate CRM List Component in Sharepoint

Last week I installed a new CRM and Sharepoint enviroment on my client.  I had a strange problem when I tried to install and activate List Component on Sharepoint: After the installation (I did not have any problem during the process) I tried to activate List Component Plugin: The result was that the plugin was not active but I did not have any error. After some (long) minutes, I found the problem:

Inside zip package setup for CRM List Component there is a powershell file named AllowHtcExtn.ps1

We need to execute this file before activate.

On Technet we can read this :

[…By default, HTML component (.htc) files aren’t enabled on SharePoint 2013. …]

 

After we can activate our plugin.

That’s all 🙂

Sharepoint Error schema database (Version problem)

Last week I migrated Sharepoint database from a server to another one. I did not have any problem with restore database on new server but the problem started when I tried to add the new content database to sharepoint. I had this error:

This content database has a schema version which is not supported in this farm.

img4

After some check and some scounting on Google, I found the reason: The version of Sharepoint where I get the database is different from the version where I tried to install it.  In my case the problem was that on the destination server the Sharepoint Service pack 1 was missing. After installation of Service pack I could add the new content database.

To check the build version, I open the “Manage Patch Status” from Sharepoint Central Administrator:

img5

That’s all… 🙂