Skip to main content

See the Point

Go Search
  

See the Point > Posts > Vanity thy name is… SharePoint?
Vanity thy name is… SharePoint?

I have been at several companies that deployed SharePoint as their intranet, made use of team sites, even made classroom sites and other things. At each of these places, the companies were content to have a single URL and have managed paths for site collections. I am now at a company that has acquired many smaller companies. These companies have maintained their identity and need to have their own URLs within the company intranet and internet SharePoint farms.

The best practice is to keep the number of web applications to as few as possible as performance degrades as you add more. According to the article here, 99 is the maximum. (Thanks to Todd Klindt for the link to the article when I couldn’t find it.) If we allowed all of these smaller entities to have their own, we would hit that number quickly. So we decided to look at host-named site collections.

There are 2 articles from TechNet on host-named site collections, one for WSS and one for MOSS. These have some excellent information and I referred to them often when implementing. However, I ran into some things that weren’t detailed in these articles, and after scouring the net (yes, I Bing-ed instead of Googled) found a lot of good information. One thing I learned, the common terminology for this is “Vanity URL.” I can totally understand why! Most of the articles I read were about departments that wanted to have their own “special” URL separate from the company. So I stuck with this terminology, since it is much easier to remember and a little less of a tongue twister!

So this is my story and I’m sticking to it!

First, I created a web application with a URL that we had registered in DNS. Now, these servers are going to be in production one day, but are not currently, so I created them with a temporary URL. This will one day be changed to replace the current intranet URL, and I’m sure you will see a future blog post about how that works!

After creating the web application, I went to create the site collection with the vanity URL. This URL was already registered with DNS, and needed to be used quickly, before the rest of the internet migration takes place. I created this using a command line as shown here:

stsadm.exe –o createsite –url http://vanityurl.company.com –ownerlogin domain\username –owneremail email@company.com –hhurl http://site.company.com –sitetemplate BLOG#0 –title “Vain Blog Site” –quota TeamSite

After it completed, I tried to browse to it. And was met with this:

clip_image002

Yeah, that’s exactly what I wanted to see, right? How to make this work correctly? Well, here are the steps I had to take to make it work.

1. Create a site collection at the top level of the web application. I created a blank site, since I knew one day this would be something else and we had plenty of time to develop that part.

2. Forget all of those instincts that say “Don’t touch IIS, let SharePoint manage the host headers.” I went to the main web site properties in IIS and added the vanity URL as a host name to the main web application.

This got me closer, but still didn’t completely correct the problem. I was still getting an error when trying to browse to the site. What next? When all else fails, reset IIS, right? So after an IIS reset, I was finally able to browse to my very own site collection by its Vanity URL!

Now remember that you need to go into the search settings and set up search to crawl this content. If you use vanity URLs it will not be automatically crawled with the search set to crawl all SharePoint sites. When I go to set the new AAM for the top level of the web application, I’ll be sure to take good notes if it breaks everything!

Comments

Re: Vanity thy name is… SharePoint?

Hi Lori,

Great way of explaining this feature and providing a good overview. Just wanted to post there are some limitations to HH site collections.  Here are some of them as I understand it currently:

- SSL will not work for a host header site collection unless it is using a wildcard certificate and the host header is in the same domain
- They do not show up in AAMs (as you noted) so that means SSL termination will not work with them
- AAMs are not used as part of site lookup for HH Site Collections, so URL re-writing will not work
- I know there were earlier issues with backup/restore and blob caching but they may have been resolved in updates

JD Wade
@jdwade
at 9/14/2009 3:07 PM

Response to JD

JD,

Thanks for adding these tips! I had noted that SSL would not work, but since we are not implementing SSL I had not done any experimentation with it.

Lori
Lori Gowin at 9/14/2009 3:18 PM

Re: Vanity thy name is… SharePoint?

This is really cool, thanks for sharing your experience. Please let us know if you run into any issues (I hope not).

@wahidsaleemi
at 9/21/2009 5:21 PM

best way to restore?

Hi Lori,
I am struggling with a similar issue - but instead of creating a new site - I want to restore a fresh copy over a previously restored site. I have created my site with this vanity
http://test-sitename and wnante to restore the fresh copy and then once eveything is restored and tested change the vanity url to http://sitename

I ran accross you post here because I have run into the issue of broken images (relative) - can you give me any advice?

It took me forever to get my site back up and running as we have alot aof packages to deploy and several manual customizations - and the search settigns etc. So I don' want to start fresh
at 12/1/2009 5:15 PM

Add Comment

Items on this list require content approval. Your submission will not appear in public views until approved by someone with proper rights. More information on content approval.

Title


Body *


Date *

Enter today's date
Attachments

 About Me

Lori 
Lori Gowin
SharePoint Administrator

Lori is a SharePoint Administrator who has been working with SharePoint and InfoPath technologies for over 4 years. When not focusing on SharePoint, Lori unwinds watching sports and spending time with her husband and children.

EUSP-LiveBlogger