0
votes

I would like to create multiple site collections like http://site1.contoso.com , http://site2.contoso.com in a SharePoint 2010 web application http://portal.contoso.com. So i have followed the host named site collection approach suggested on http://technet.microsoft.com/en-us/library/cc424952(v=office.14).aspx

i tried running the following command on powershell

New-SPWebApplication -Name "HNSC01" -Port 80 -HostHeader http://HNSC01.contoso.com -URL -ApplicationPool ContosoAppPool -ApplicationPoolAccount (Get-SPManagedAccount <server>\<user>) 

Here URL seems to be out of place and since it is parameter i tried running the command with out URL and this is not getting executed at all.

Here are my questions.

  1. I would like to know if i am in the right direction or not?
  2. Is there better way of achieving the same result?
1
I am able to run the command with the -HostHeader HNSC01.Contoso.com and create the host named site collection using the host header.Nayan

1 Answers

0
votes

I am able to create Host Named Site Collection(HNSC) using powershell script as per the information provided in the blog but i am open to any other suggestions of achieving the same goal by some other means if there are any better solutions.

http://blogs.msdn.com/b/markarend/archive/2012/05/30/host-named-site-collections-hnsc-for-sharepoint-2010-architects.aspx