Wednesday, September 14, 2011

Configuring My Site in SharePoint 2010

SharePoint My Sites are commonly referred to as “Facebook for the enterprise” and are personal site collections providing each user with the ability to store private and public information such as documents, pictures, status updates, etc easily and efficiently.  My Sites in SharePoint 2010 takes social enterprise computing to the next level and builds upon what we have come to love in previous versions.  Microsoft saw the need to continue to invest and enhance SharePoint’s social networking capabilities, and as web 2.0 technologies continue to sprawl all over the world wide web, Microsoft have again successfully set the bench mark in the enterprise by introducing an array of social computing features to enhance end user collaboration in SharePoint 2010.
In my last article I introduced and configured our first service application for our SharePoint 2010 deployment, User Profiles, which provided us with a central location for storing user details that will later be imported from a content source such as Active Directory.  Today we will continue our journey to plan and configure User’s My Sites in SharePoint 2010.
Prerequisites
This article is the 5th in my series on deploying SharePoint 2010 for the enterprise, so if you have missed the first 4, you can easily catch-up via the links below;
  1. Installing SharePoint 2010 using Least Privilege Service Accounts
  2. Configuring incoming email in SharePoint 2010 with Exchange 2010
  3. Configuring outgoing email in SharePoint 2010 with Exchange 2010
  4. Configuring the User Profile Service in SharePoint 2010
Create the My Site Web Application
We begin by first creating a Web Application that will eventually house our My Site Host and subsequent site collections.
Navigate to Central Administration / Application Management / Web Applications
Click New
image thumb Configuring My Site in SharePoint 2010
Authentication: Select either Claims or Classic depending on your requirements.  I will select “Classic”
IIS Web Site: Create a new IIS web site (enter your details as per your requirements)
image thumb1 Configuring My Site in SharePoint 2010
Authentication Provider: Select your preferred provider based on your requirements.
Public URL: Specify the URL that users will type to access their My Sites.
image thumb2 Configuring My Site in SharePoint 2010
Application Pool: Create a new application pool and give it a descriptive name
As we have been utilizing the least privilege model whilst configuring our SharePoint farm in this series, we will click on Register a new managed account and enter the details for our My Site Application Pool Identity.  Note: This account will be required to be provisioned in Active Directory before you can proceed. e.g. In my example I have created an account called DOMAIN\sp_mysite.
image thumb3 Configuring My Site in SharePoint 2010
Click OK
image thumb4 Configuring My Site in SharePoint 2010
Database Name and Authentication: Specify your Database server and Database name.
Failover Server: Specify your failover server if you are utilising SQL Server database mirroring.
image thumb5 Configuring My Site in SharePoint 2010
Click OK
You should receive the below confirmation that the Web Application has been successfully created.
image thumb6 Configuring My Site in SharePoint 2010
Click on our newly created “SharePoint – My Site” Web Application and click on General Settings.  Proceed to fill out your Web Application specific settings such as the Default Time Zone etc.
image thumb7 Configuring My Site in SharePoint 2010
Create the My Site Host Site Collection
Now that we have successfully created our My Site Web Application, we can now proceed to create our My Site Host Site Collection.  This will be the top level site that will house our individual user’s site collections.
Navigate to Central Administration / Application Management / Create site collections.
Ensure that the recently created My Site Web Application is selected, enter in a Title and click select the My Site Host Template located under the Enterprise Tab.  Lastly, specify your site collection administrators and click OK.
image thumb8 Configuring My Site in SharePoint 2010
You should then receive confirmation that the top level My Site Host has been successfully created.
image thumb9 Configuring My Site in SharePoint 2010
Setup My Sites
Now that we have successfully provisioned our My Site Web Application and Top Level Site Collection that will host our My Sites, we can continue to configure our My Site Settings.
Navigate to Central Administration / Application Management / Manage service applications.
Click on User Profiles.
Click on Setup My Sites located under My Site Settings.
image thumb10 Configuring My Site in SharePoint 2010
Enter the details of your Preferred Search Center if you have one setup already.
Enter the URL of your My Site Host that we have just created in the previous step and the personal site location.
image thumb11 Configuring My Site in SharePoint 2010
Finally, select your Site Naming format, configure your Language Options, Permissions and My Site Email Notifications.
image thumb12 Configuring My Site in SharePoint 2010
Click OK.
Add our Managed Path
Because we have specified “personal” as our Personal Site Location, we will need to define our managed path against our My Site Web Application.
Navigate to Central Administration / Application Management / Manage Web Applications.
Click on your My Site Web Application and click on Managed Paths from the Ribbon.
image thumb13 Configuring My Site in SharePoint 2010
Add “personal” as a Wildcard inclusion, click Add Path and click OK
image thumb14 Configuring My Site in SharePoint 2010
Enable Self-Service Creation
Our last configuration step provides our users with the privilege to provision their own My Site’s by enabling the Self-Service Creation.
Navigate back to Central Administration / Application Management / Manage Web Applications.
Click on your My Site Web Application and click on Self-Service Site Creation.
image thumb15 Configuring My Site in SharePoint 2010
Select On and click OK.
image thumb16 Configuring My Site in SharePoint 2010
If I now browse to my My Site URL I will be presented with the following “What’s New” Page.
image thumb17 Configuring My Site in SharePoint 2010
It is only until I click on “My Content”, that SharePoint will proceed to create my personal site as per SharePoint 2007.
image thumb18 Configuring My Site in SharePoint 2010
My Content
image thumb19 Configuring My Site in SharePoint 2010
As you can see, we have now successfully completed our setup of a My Site Host which will house our user’s My Sites.

Console Application error: The Web Application at could not be found

When we create the Console applications in SharePoint 2010 Server,  their application kept on getting the following error, when trying to create a new instance of SPSite:
System.IO.FileNotFoundException: “The Web application at http://sharepointsite could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application.”
image
To fix this in SharePoint 2010, there are a few things that should be done:
1. Under Project Properties –> Application, Ensure that the target framework to be compiled against is .NET Framework 3.5

image

2. Under Project Properties –> Build, Ensure that the platform target is set to x64

image

3. Ensure that the SPSite URL you are trying to open is in your Central Admin –> Web Application alternate access mappings

SharePoint 2010 Metadata and Taxonomy Management

I finally got around to reading the preliminary SharePoint 2010 taxonomy and metadata info on MSDN. As most of you know, MOSS 2007 had some serious challenges in this regard (e.g., no hierarchical metadata, no sharing controlled vocabularies across site collections, etc.) — and they caused information architects like me much consternation.
It would appear that SharePoint 2010 includes many new features under the umbrella of Enterprise Metadata Management, and they seem to have addressed some key issues. Here are the highlights.

1. Terms & Keywords

SharePoint 2010 has a few types of vocabularies with different levels of control:
Terms: Basic construct — a word or phrase that can be associated with content. A term can become a managed term or a managed keyword.
Managed Terms: A controlled term that can only be created by those with appropriate permissions. Term sets (think of them as taxonomy facets) are collections of related terms that can be hierarchically structured.
Managed Keywords: User-generated keywords (aka tags) kept in a non-hierarchical list called the keyword set.
What's nice is that you can easily turn a managed keyword into a managed term, which essentially sets up SharePoint 2010 as a decent platform to blend taxonomy and folksonomy approaches (more on this later).


2. Managed metadata & the Term Store

Once you have managed terms in place, you can create a new column type called "managed metadata". This column type is like the 2007 lookup, but points to the managed term sets instead of lists.
One of the biggest limitations of MOSS 2007 was the site collection boundary: lists were specific to a site collection, so in order to share metadata and taxonomy across multiple collections, you had to essentially reproduce the same lists in each collection.
Managed term sets (and managed keywords) now live in what's called the Term Store Management Tool — a centralized database that allows term sets to be shared across a farm.
sp2010-metadata-20091112-01.png
SharePoint 2010 — Centralized Metadata Repository. Image courtesy of EndUserSharePoint.com


3. Taxonomy & Metadata Management

Within the Term Store, there are some metadata and taxonomy management functions enabled, though the documentation is not clear on how many of them are achieved.
Feature Comment
Create or delete term sets Term sets can also be thought of as facets
Add, modify or delete terms It is unclear however how modifications and deletions are propagated throughout content that is already tagged - this is a big problem in 2007, as changes are not reflected in tagged content
Arrange terms in hierarchies It would appear that this uses a drag & drop mechanism
Define synonyms Unclear as to how this works and whether it is used in the search thesaurus
Import terms Via a .CSV file
Promote managed keywords into managed terms Great news for those of us who want to use tags as a source of candidate terms for the taxonomy
Create multi-lingual     taxonomies Unclear if this is at the term level or you have to create language-specific versions of each term set… likely the latter
My biggest concern is the whole question of integrity and change propagation, but overall this is a huge leap forward from 2007 where there was no taxonomy management to speak of. This is actually more functionality than I've seen in many very expensive CM suites, so right now on the surface, I'm rather pleased with this set of features.

Using Managed Metadata in SharePoint 2010


Managed Metadata is a really cool new feature in SharePoint 2010. You can centrally define metadata which can be used across Site Collections. This Term Sets can be statically defined by a Group Manager or dynamically extended by your users. I will show you how to create such an Group and Term Set and how to include it in a Document Library.

First of all you have to start the required Web Service. So within the Central Administration click on the link “Manage services on server“.


There you’ll find the “Managed Metadata Web Service“. Use the “Start“-Link on the right side to start it.



Now we have to create a service application which handles the managed metadata. In Central Admin within the Application Management use the Manage service applications link to get an overview of the currently created service applications.
Side Note: Service Applications are the follower of the Shared Service Provider (SSP) in SharePoint 2007.


Use the New Button at the Service Applications Ribbon and choose “Managed Metadata Service“.



Enter your desired options. The options are self-explaining.
After the creation process you find your new service application in the list. Click on the Name of the Service Application or highlight it and use the Manage Button within the Service Applications Ribbon to enter the Term Store Management Tool.



First of all we have to create a new group for our Term Sets. When moving the pointer over the name of your Service Application (in my case its “Managed Metadata Service SA”) a little arrow appears. After clicking on this arrow the below showed menu appears. Now use the New Group link and enter the name of the group.




After entering the name you can hit Enter and the properties of this group are displayed. I think the options here are self-explaining as well.


Now create a Term Set which will hold our Terms (Metadata). The Term Set is the part which will be used in a column. Basically it’s the same process as the creation of the group. Move the pointer over your group, click on the small arrow and choose New Term Set. It’s also possible to import a CSV-File.



After hitting Enter again you’ll find yourself in the properties of this new Term Set. Especially the “Submission Policy” setting is interesting. If you want a dynamic list (which is extendable by your users) you have to change this option to Open.



Once again, we have to use our little arrow to create new Term’s inside this Term Set.


You can define multiple synonyms for each term. If this synonym is typed by one of your users the right Term will be displayed as suggestion.


So, after all you Term Set was created we should also use it ;)
Create a new column in a List or Document Library within your Site Collection.






Enter a Column name and choose “Managed Metadata” as information type.


Puhuu, what’s that? ;) I’m not sure if it’s just a bug within the RC1-Edition, but we have to enable the Term Navigation through PowerShell. Yep, the required feature isn’t available through the “Site Feature” list inside the “Site Settings”.



Start PowerShell and add the SharePoint SnapIn so the required cmdlets are available.
Get-PSSnapin –RegisteredDisplays all PowerShell-Snapins which are available on your machine
Add-PSSnapin Microsoft.SharePoint.PowershellAdds the SharePoint-Snapin to this PowerShell session



If you don’t trust me that you have to enable the feature you can check it ;)
Get-SPFeature –Site <URL to your Site Collection>Displays a list of all already enabled Site Features
Enable-SPFeature -Identity 73EF14B1-13A9-416b-A9B5-ECECA2B0604C -Url <URL to your Site Collection>Enables the “TaxonomyFieldAdded” feature for the specified Site Collection. This one is required for the Taxonomy Browser.
Get-SPFeature | where {$_.displayname –like “*tax*”}
A list of all available features on this Farm are displayed which have tax in their name. This would be an option to get the ID of the feature. The other option would be to try to create a column while this feature is disabled. You will receive the error: “The Taxonomy feature (Feature ID “73EF14B1-13A9-416b-A9B5-ECECA2B0604C”) has not been activated.<br>A term set or anchor point was not selected”.





So, feature is activated and we’re ready to use it. Refresh the page. Now your Managed Metadata Service Application with the Group and Term Set is display.


If you want the Term Set to be dynamically extendable set “Allow ‘Fill-in’ choises” to “Yes“.
After using the “OK-Button” to create the new column just upload a document. Our column is displayed and while you’re typing a value relevant suggestions are displayed. You can also click on this tiny cards (or whatever it should be) on the right side of the input box to display all available Terms. This is also the required step if you want to add a new Term.



Use the “Add New Item” to, what a surprise, add a new term ;)


That’s it ;) You can also try to add a column which is using your Term Set on another Document Library and even on a DocLib within another Site Collection and you’ll find all Terms.
There are still some open questions for me where I have to play more with this feature. Especially with permission on the Term Sets and Groups. But all Managed Metadata would solve a lot of troubles we all had with SharePoint 2007.
In my opinion it’s just important to clearly understand the impact of Managed Metadata and to plan it carefully. It’s like with Content Types => A good concept is everything ;)