SharePoint 2010 Development Machine with Office 2013

If your trying to setup or change the configuration of SharePoint on a development machines which has Office 2013 install you may encounter some strange errors relating to types such as:

Failed to call GetTypes on assembly Microsoft.Office.InfoPath.Server, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c. Could not load file or assembly ‘Microsoft.Office.InfoPath, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c’ or one of its dependencies. The system cannot find the file specified.

This is related to the way in which SharePoint is loading certain assemblies and struggles with the new assembly for InfoPath. Thanks to Hermanote for the workaround which is to remove the InfoPath feature from office only, and the error goes away.

Advertisements

SharePoint 2010 State Service Database

I recently found a small bug in the SharePoint 2010 PowerShell comlets for creating the state service database using “New-SPStateServiceDatabase”.

You will receive the rather unhelpful error message “Operation is not valid due to the current state of the object”. I believe this is a generic WCF error as that’s all I was able to find when researching what may cause the problem. However, it later transpired that this was because I was trying to use a database alias (or potentially database server) which SharePoint isn’t currently aware of, as using the alias (or database server) that was used for the initial farm setup didn’t result in the same issue.

Its taken me a while to find this one as the state service isn’t usually one of the first service applications I configure, so it appears most of the other service application creation cmdlets don’t mind registering a new database host, but for some reason this one does!

If you use sql alias (as a best practice you should) and have a different alias for service applications, I would advise creating another service application before creating the state service database in order to make sure SharePoint is aware of the alias/dbserver.

Lync 2013 – Front End Server ‘Starting’

Upgrading Lync to 2013 recently I came across a problem where the front end service simply wouldn’t start but would get stuck in “Starting” mode.

I spent quite a bit of time trying to figure out what the problem was and got caught up in some false information on the technet forums that it was related to Server 2012. In fact the problem was fairly simple if you know whats going on under the hood.

When the server firsts starts it synchronises user information from active directory, but here’s the kicker, if you have multiple domains in your active directory forest regardless of where the server lies, it will try to get user information from the other domains, if it can’t it won’t start, and in most cases you have probably like me only run the domain preparation step on the domain you want to use with Lync.

There’s two ways to resolve this depending on your requirements,

  1. Run the domain preparation step on all domains in your active directory forest.
  2. (My Preferred) Limit the user replication to the domain you want to use with Lync with the following powershell:
    Set-CsUserReplicatorConfiguration -Identity global -ADDomainNamingContextList @{Add="dc=fabrikam,dc=com"}

The PowerShell included above will limit the replication to the “fabrikam.com” domain only, misleading as the command may be (‘Add=’) as default the value is null (you can check with “Get-CSUserReplicatorConfiguration”) which essentially means all domains.

I didn’t find this issue to be that well documented or resolution 1, so hopefully this will help anyone else out there who has the same problem (and maybe remind myself if I ever want to include additional domains and can’t figure out why I can’t enable the users for Lync).

Big thanks to “JMTTech” on the technet forums for this one http://social.technet.microsoft.com/Forums/nb-NO/lyncserverpreview/thread/07ec9d8c-b83e-4795-91b6-0d3344cd49e5