88 articles and 356 comments as of Friday, April 20th, 2012

Tuesday, May 11, 2010

Life is Just a Bowl of SharePoint – Part 11: Creating Web Applications and Site Collections

Guest Author: Joan Resnick Ehrlich

Continuing with Configure Kerberos authentication (SharePoint 2010) in the SharePoint Server 2010 Library on TechNet, I created the Intranet and My Site web applications. As mentioned in Part 8, for each web application I used a host header and a separate application pool with a unique managed account. I also made sure Kerberos authentication was selected.

Creating a web application from within Central Administration is done via Application Management, Manage Web Applications, New button. Here are the settings I used for the Intranet web application:












As this is a beta, I enabled the Customer Experience Improvement Program. I would not enable this for our production environment.

Creation was successful and I received a message accordingly:


I then repeated the process for the My Site web application, making sure to enter a different Database Name. I kept the default of host header + port number for the virtual directory path (which in the screenshot is not fully visible). For the public URL I could have deleted the port number (80) as I did for the Intranet’s URL above. As port 80 is the default port for http, users do not need to add the port number to the URL. Leaving the port number in or taking it out of the public URL makes no difference when accessing the web applications. Users only need to use a port number when accessing web applications located on non-default ports; that is, located on a port other than 80 for http and other than 443 for https.]










Next up: Creating the site collections, starting with the intranet site. The TechNet documentation (as of this writing) says to select “Collaboration Portal” for the template but there is no such template available for selection. SharePoint Technical Product Manager Bill Baer (MSFT) explained in this forum post http://social.msdn.microsoft.com/Forums/en/sharepoint2010general/thread/057d0264-8df5-4a6f-a39a-8995e56f4d49 that the template has been deprecated and does not show up in the UI, but that it remains as a site definition in 2010 to support MOSS upgrades. I found out via another forum post that it is listed in the output of the PowerShell command Get-SPWebTemplate, which lists all available site definitions.

Coming from WSS I had to do some reading about the enterprise level templates. Which Sharepoint 2010 Site Template is Right for Me by SharePoint MVP Todd Baginski delineates the out-of-the-box site templates and the templates for creating sub sites, pages, and lists that are available by default under each. It came down to Publishing Portal or Enterprise Wiki. The Publishing Portal provides by default only a limited number of site templates for sub site creation but I found instructions for adding the rest at http://praveenbattula.blogspot.com/2010/02/sharepoint-2010-site-templates-not.html, which also notes that the same method can be used for adding page layouts. Here are some more posts on the same topic: Where Are My Site Templates by Sean Earp (MSFT) and http://manish-sharepoint.blogspot.com/2010/03/defining-default-layout-page-for-new.html, which provides step-by-step instructions for adding page layouts.

As we will have mostly read-only pages at the top-level site of our intranet site collection the Publishing Portal seems better suited for our needs. We will create an Enterprise Wiki as a sub site directly below. Here is a screenshot of the Create Site Collection page for the Intranet web application:




After the site collection was successfully created I had to verify that Kerberos authentication was working. Using my Windows 7 laptop I opened the site in Internet Explorer and was greeted by a login prompt. Logging in worked, but how to eliminate the login prompt? Adding the site to the Trusted Sites zone, which is what typically works, did not help. I had to add the site to the Local intranet zone to eliminate the login prompt. [The tip is thanks to a forum post I did not save a link to.] In order to add sites to the Local intranet zone I had to click the Advanced button:


A look at the Security Event Log on the SharePoint server showed that Kerberos authentication was working, so I moved on to creating the My Sites site collection, which proved a bit more complicated. The TechNet documentation says to navigate to the My Site site using the [root] URL and SharePoint will automatically “create a My Site for the logged on user”, after which the “My Site page for that user should render”. Ok, but in what universe? The documentation did not address how to set up My Sites – neither the managed paths nor the root and My Site Host site collections, nor the required User Profile Service Application and its configuration. And since I was strictly following the documentation I had not yet done any of this. Time to make up a Plan B…

I found setting up My Sites a bit daunting. I had read a little bit about My Sites in MOSS but otherwise ignored the feature, and what I knew about My Sites in 2010 was what I had come across when researching other areas. Still on my must read list, which extends beyond SharePoint, is the Social Computing and Collaboration Planning section of Planning and Architecture and My Site settings section of Operations in the SharePoint Server 2010 Library on TechNet. But between SharePoint MVP Liam Cleary’s step-by-step post SharePoint 2010 – My Sites and Jeremy Thake’s SharePointDevWiki post Configure User Profile Synchronization Service I was able to get User Profile Synchronization working and My Sites up and running.

First, I ran the Farm Wizard and created all of the service applications except Lotus Notes Connector. That got me a User Profile Service Application. I then started the User Profile Synchronization service, which starts the two Forefront services visible in the Services MMC snap-in (services.msc) and changes their startup type from Disabled to Automatic. [My understanding is that SharePoint needs to start these services; the services should not be manually started.] The service took a while to start and yes, seeing “Starting…” for an inordinately long time despite a page refresh every two seconds can test anybody’s patience. But once it did the Forefront services showed Started and their startup type had changed from Disabled to Automatic.

Creating a connection to Active Directory was next. The first few times the creation did not take. I was able to populate the “Add new synchronization connection” settings with the AD containers and select the organizational unit (OU) I wanted but when I clicked Ok and was brought back to the Synchronization Connections page the connection did not show up. All I saw was “The query returns nothing” which is the message when no connections exist. An Internet search later and this: http://www.khamis.net/blog/Lists/Posts/Post.aspx?ID=19 led me to figure out that I had to explicitly add the logged in account (spsadmin) as a User Profile Service Application administrator. [I added myself as well so I can also manage connections.] Once I did that and recreated the connection the connection was saved and showed in the Synchronization Connections page. I then started a Full Synchronization. I had selected an OU with four users in it so I expected the synchronization would not take any time at all. Wrong. It took 20 minutes.

After the synchronization finished I created two managed paths for the mysite web application: /my (explicit inclusion) and /personal (wildcard inclusion). An explicit inclusion means only one site collection can be created at that exact URL (in this case, at /my). A wildcard inclusion means many site collections can be created under the specified URL path (in this case, under /personal). Here are explanations of managed paths: SharePoint 101 – Managed Paths by SharePoint Program Manager Zach Rosenfield (MSFT) and http://manish-sharepoint.blogspot.com/2009/02/using-managed-path-with-implicit.html.

Creating the My Site Host site collection followed.  Selecting the /my URL path (Web Site Address section) and the My Site Host template (Template section, Enterprise tab) is the key to success:



Finally, I created a blank site collection at the root URL in order to make the self-service site creation button available in the ribbon on the Manage Web Applications page. I chose the Blank Site template as it seemed appropriate. Note that only the / (forward slash) is chosen in the configurable part of the Web Site Address URL; the / designates the root level.




Once the site collection was created I turned on self-service site creation and set up the My Site parameters in the User Profile Service Application. After that I got a bit lost. I was not sure what URL to navigate to, to create a personal site for myself. I expected my personal site to be created at /personal/USRE_joan, so I navigated to /personal but all I got was a 404 Page Not Found error. I then tried the /my URL which got me to the My Site Host site. I clicked on the My Profile link under my name in the upper right corner, which landed me at /my/Person.aspx?accountname=USRE%5Cjoan. I then clicked back to /my and clicked on the My Content link. SharePoint threw up a message about please wait while it creates my personal site, after which I ended up at /personal/usre_joan/default.aspx. I was getting somewhere but where? My Profile was at the /my URL and My Content was at the /personal URL. Aside from feeling like I was stuck in the Abbot and Costello routine “Who’s on First”, I seriously thought I had a disjointed site. I then clicked on My Network, which landed me at the My Site Host site. It was definitely time for an internet search. Thankfully, I found this rather quickly: http://www.alpesh.nakars.com/blog/set-up-my-site-in-sharepoint2010/. A close look at the enlarged screenshots showed that my URL setup matched. So I guess My Sites is set up correctly after all and I just need to do a bit of reading to understand the reason two URL paths are used for a user’s My Site.

I should note that during the personal site setup process I received this message, to which I clicked No, as it took me by surprise and I first want to research the feature:


The final step in the TechNet documentation was to confirm Search Indexing and Search Query functionality worked correctly. I uploaded a document to the Press Releases Documents library, as good a place as any to test, and initiated a full crawl from the Search Service Application in Central Admin. The crawl completed successfully, but a search for the document did not turn up any results. Reading through the Post-installation steps for Search instructions under the Initial Configuration section of the SharePoint 2010 Library I realized that the Intranet site did not have a “tab named Search Center”. So I created a Search Center site as a sub site under the Intranet root site. This is the structure we will use in production rather than a dedicated site collection specified in the aforementioned documentation. I used the Enterprise Search Center site template, which provides People search; the Basic Search site template does not. If you do not see the Enterprise Search Center site template, http://www.dotnetmafia.com/blogs/dotnettipoftheday/archive/2010/03/11/dude-where-s-my-search-center.aspx steps through how to make it available. After the sub site was created, “Search Center” showed up in the Intranet home page Quick Launch. No top navigation tab but good enough. I then specified the Search Center site path in the Intranet’s Site Settings, Site Collection Administration, Search settings and initiated another full crawl. This time my uploaded document appeared in search results.

With Search Indexing and Search Query functionality verified I had completed the Configure Kerberos authentication (SharePoint 2010) documentation. I’ll leave the rest of search configuration for the RTM. Incidentally, I noticed that there is no breadcrumb navigation or any other visible means of navigating away from the Search Center site other than using the browser’s Back button. Changing the Navigation settings had no effect. I have also since noticed that a “Search” sub site (also without visible means of navigation) already existed under the Intranet root site and that it was created when I created the Intranet site collection. The site template that was used appears to be the Basic Search site template, because “People” is not an available search option.

Now that SharePoint 2010 RTM is available I will not be continuing with the Beta. As soon as SQL Server 2008 R2 RTM is available I will reformat the servers and install the RTM versions. I will report on the differences, if any, from the Beta installation in my next article.

Guest Author: Joan Resnick Ehrlich

Joan Resnick Ehrlich has been in the IT industry for 15 years and is Corporate IT Administrator for a mid-sized company on Long Island, NY. Prior to entering the industry Joan was a business researcher, and she enjoys combining her research skills with IT work. In addition to SharePoint, her primary responsibilities include Windows Server, Active Directory, Exchange Server, and SQL Server.

Bookmark and Share
 

Please Join the Discussion

4 Responses to “Life is Just a Bowl of SharePoint – Part 11: Creating Web Applications and Site Collections”
  1. Alpesh Nakar says:

    Joan,
    Very comprehensive write up! Good one. Thank you for the link back too!

  2. Joan says:

    Alpesh,
    Thanks! And for the help too – I depend on the community every day in my job and much appreciate everyone out there.

  3. Neel says:

    Joan,

    Good write up!! Keep it up

    I have question with Mysites, used the mysite host got the mysite set up, I see below liks on the top link bar

    My Network | My Content | My Profile | My Site

    All the above links are working except the My site.. how can i set it up?

    Neel

  4. Joan says:

    Neel,

    If you’ve got My Content working (page includes Shared Documents and Personal Documents web parts) and My Profile working (page includes tabs for Overview, Organization, Content, etc), and My Site says “Stay Connected”, that is what I have. All three = a user’s My Site. At least, that is my take.

    btw, are you still using the Beta? In the RTM my top link bar says (from left to right) My Site, My Newsfeed, My Content, My Profile. There is no “My Network”. The My Site page “Stay Connected” has 3 links on page: My Collegues (which is link to Colleagues tab on My Profile page), My Interests, Newsfeed Settings.

    Joan

Subscribe without commenting

Speak and you will be heard.

We check comments hourly.
If you want a pic to show with your comment, go get a gravatar!