Learning how to do things and fix stuff as I go because who really has time to sit in a classroom. Posting it all here because I can not remember it all.
Saturday, October 22, 2011
Missing FAST Administration Links
I just upgraded some of my sites to SP1 + June CU and the Administration Links for FAST disappeared. Very simple fix described here: Updating SharePoint Server 2010 from RTM to December or later Cumulative Update disables FAST Search links in site collection administration (KB2521577)
Monday, October 17, 2011
Unable to install Hotfix for Microsoft Windows (KB976462)
While installing FAST Search for SharePoint, I came across this error:
Error: The tool was unable to install Hotfix for Microsoft Windows (KB976462). If Hotfix for Microsoft Windows (KB976462) is already installed you may need to uninstall it and run prerequisite installer again.
It turns out all I have to do is run the installer again since I was running Windows 2008 R2 SP1 which already has the necessary fixes.
Reference: KB2581903
Error: The tool was unable to install Hotfix for Microsoft Windows (KB976462). If Hotfix for Microsoft Windows (KB976462) is already installed you may need to uninstall it and run prerequisite installer again.
It turns out all I have to do is run the installer again since I was running Windows 2008 R2 SP1 which already has the necessary fixes.
Reference: KB2581903
Saturday, October 8, 2011
Formally learning SharePoint 2010
It's been a little over a year since I have started on SharePoint 2010. It was my first real exposure to SharePoint in any real depth (Yes, I have dabbled with SharePoint since STS, but never to an appreciable degree). Now I am planning to formalize some of my learning by taking a course and getting a certification. I figure the one I will go for is 70-667 TS: Microsoft SharePoint 2010, Configuring. Looking at the various offerings, it looks like the in class 10174 course is overkill (5 days, 9-5, $2000-3000). So, I have decided on the online collection 10278: Microsoft SharePoint 2010, Configuring course and supplement with various technet resources, virtual labs, other people's experiences such as How I passed SharePoint 2010 exam 70-667, and SharePoint 2010 Configuring 70-667 Exam Passed!.
Determining who has an open file handle on DLLs in the GAC
I recently needed to update a solution in my SharePoint farm however:
- The update required administration and connection permissions to the User Profile Service Application (UPA)
- Some assemblies in our solution was causing the the UPA to be inaccessible
So, my code is broken and needed update, my update is broken because it can't access UPA, my UPA is broken because of my code ... argh!
Then, I had this idea, figure out which DLLs were breaking the UPA and update those directly in the GAC, hoping that it will at least free up the UPA so the update. I figured my DLLs were reasonably compatible over the different versions. So this is what I did:
- Grab my updated WSPs
- Use 7-zip to open the WSPs and extract the DLLs I needed
- Open up the GAC (C:\Windows\Assembly)
- Copy the DLLs I need into the GAC
- Verify, by version number, that my DLLs were indeed copied into the GAC (I have seen cases where the copy seems to work, but nothing actually happens)
- iisreset
- restart owstimer
- Run my installer to update my code as normal.
This worked very well for me, but when a colleague tried it, he found that he was unable to get step 4 working. He kept getting access denied issues. It turns out that he had UAC turned on and some processes (not just iisadmin) had an open file handle on the very DLLs he needed to update. Getting around the UAC issue is just a matter of running things as administrator. To solve the file handle issue, we used Handle from Sysinternals.
Now it was simply a matter of opening up a command prompt and doing something like this:
Handle.exe c:\Windows\assembly\gac_msil\<your DLL name>
Handle will also recurse into subdirectories for you! Now it's just a matter of stopping those processes and continuing on.
Friday, September 16, 2011
KB2560890 update without SharePoint SP1
It appears that the Security Update for Microsoft SharePoint Server 2010 (KB2560890) breaks the User Profile Service Application if you don't have SP1 installed for SharePoint 2010. The error I am seeing is:
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.ResourceManagement, Version=4.0.2450.34, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified
According to UserProfile not working after security update KB2560890, it seems like others are having the same issue.
The file list for KB2560890 refers to version 4.0.2450.34 of various Microsoft.resourcemanagement.* files, but does not specifically list Microsoft.ResourceManagement.dll.
In my GAC, I see the following:
Microsoft.ResourceManagement 4.0.2450.5
Microsoft.ResourceManagement.Service 4.0.2450.11
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.ResourceManagement, Version=4.0.2450.34, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified
According to UserProfile not working after security update KB2560890, it seems like others are having the same issue.
The file list for KB2560890 refers to version 4.0.2450.34 of various Microsoft.resourcemanagement.* files, but does not specifically list Microsoft.ResourceManagement.dll.
In my GAC, I see the following:
Microsoft.ResourceManagement 4.0.2450.5
Microsoft.ResourceManagement.Service 4.0.2450.11
The machine had rebooted from the Windows Update. So, on a whim I decided to try shutting down and restarting the User Profile Service and the User Profile Synchronization Service (remember to iisreset if Central Administration is on the same machine).
I then checked back in my GAC and now I see the following:
Microsoft.ResourceManagement 4.0.2450.5
Microsoft.ResourceManagement 4.0.2450.34
Microsoft.ResourceManagement 4.0.2450.34
Microsoft.ResourceManagement 4.0.2450.11
Microsoft.ResourceManagement.Service 4.0.2450.34
Microsoft.ResourceManagement.Service 4.0.2450.11Microsoft.ResourceManagement.Service 4.0.2450.34
I can also manage my User Profile Service Application!
There's some sort of voodoo here, but as far as I can tell it works. Perhaps there was a continuation task after the Windows Update reboot that required yet another reboot. Who knows?!
Argh! Spoke too soon. If I go to Setup My Sites, I now get the following:
Cannot create an object of type 'Microsoft.SharePoint.Portal.WebControls.LocStringId' from its string representation 'SiteAdminPersonalSite_SocialSecurityTrimmerEnabledSectionTitle_Text' for the 'TitleLocId' property.
Time to give up and just do SP1 sometime in the future.
Argh! Spoke too soon. If I go to Setup My Sites, I now get the following:
Cannot create an object of type 'Microsoft.SharePoint.Portal.WebControls.LocStringId' from its string representation 'SiteAdminPersonalSite_SocialSecurityTrimmerEnabledSectionTitle_Text' for the 'TitleLocId' property.
Time to give up and just do SP1 sometime in the future.
Thursday, September 15, 2011
SharePoint default members group
I recently had to try to determine the SharePoint Default Members Group of a particular site. In Site Actions->Site Permissions, you can go to a group and then click Make Default Group. What's bizarre is that there is no indication which group is default, at least not in the UI. The only way I could find is in PowerShell as follows:
$web = Get-SPWeb <myurl>
$web.AssociatedMemberGroup
or you can get the ID through the property bag at
$web.Properties["vti_associatemembergroup"]
Not sure which way is better, but either works for me so far. It would also be nice to see it in the UI.
$web = Get-SPWeb <myurl>
$web.AssociatedMemberGroup
or you can get the ID through the property bag at
$web.Properties["vti_associatemembergroup"]
Not sure which way is better, but either works for me so far. It would also be nice to see it in the UI.
Tuesday, September 13, 2011
Locking down web part zones
One use case in my SharePoint demo environment is to show that certain web part pages have mandatory web parts while others can be customized by the end user. The way to accomplish this is to put the web parts in different zones. Then add the following properties to the <WebPartPages:WebPartZone> element: AllowCustomization="False" AllowPersonalization="False" AllowLayoutChange="False"
Simple! Or you could do this using SharePoint Designer.
Simple! Or you could do this using SharePoint Designer.
Subscribe to:
Posts (Atom)