Host-named site collections (HNSC) allow you to assign a site collection with a unique DNS name behind it. This differs from path-based site collections, which require you to use the same DNS name that the web application is assigned to all site collections beneath it.
Deciding when to use host-named vs. path-based site collections is a matter of your specific needs. Microsoft has a recommended a maximum of 20 web applications per farm, so host-named site collections can help a situation where one wants to have more than that above maximum unique domain names for their site.
To migrate using an existing path-based database, you need to follow the MBRRU process. This, of course, stands for Migrate, Backup, Remove, Restore and Upgrade.
This process must be done after creating the web application that will host all of your host-named-based site collections. This process will convert your content database to use host-named-based site collections.
These instructions assume that you have already installed your SSL certificate. This also assumes that the site collection for the web application you are bringing over is at the root. If this is not the case, you can still follow this tutorial, though you may have to specify the path.
Breaking the steps down a bit further:
1. Mount – This will mount the SQL backup of the SQL database from your existing source database server to SharePoint.
2. Backup – This command will back up the existing site that was just mounted to your web application.
3. Remove – This will remove the Site Collection, which is path based.
4. Restore – This will restore the site collection as hostname based, which adds the HostHeader of the web application to your mounted content database from Step 1.
5. Upgrade – This will upgrade your content database from 2013 to be compatible with the SharePoint 2016 features.
The commands you should run following the MBRRU process look like this:
Mount-SPContentDatabase -name "ContentDBName" -webapplication http://servername:port/
Backup-SPSite http://example.com:port -Path C:\SiteBackup\anyfilename
Restore-SPSite https://example.domain.com -Path C:\SiteBackup\anyfilename -HostHeaderWebApplication http://servername:port -ContentDatabase "SP2016_WSSContent_Database"
Upgrade-SPSite https://example.domain.com –VersionUpgrade
Typically, it is best to decide your site collection model while you are designing your SharePoint farm. While it is possible to change in the middle, it would be much harder since you would have downtime during the conversion. If you are interested in learning more, please contact email@example.com to talk to a DMC expert today.
Learn more about DMC's Microsoft SharePoint solutions.