create fast site collection in sharepoint 2019

create fast site collection is a new feature introduced in SharePoint 2019. Create a new site time can be reduced to half compared to New-SPSite PowerShell cmdlet by this feature. This fast site creation feature operates directly at the DB level, witpout passing to Object Model, and saving several round trips between database server and sharepoint server. So in this post we will discuss all about how to create site collection using fast site creation feature in sharepoint 2019.

Advertisements

Each site collection is associated with a blank template called a “site master”. Creating fast site, actually copies that site from DB and copies to destination site.

Fast site creation is supported with below site templates only.

You can follow my post Get template id sharepoint site with powershell to get list of templates in sharepoint 2019.

Fast creation enabled site collection templates can get using the powershell cmdlet Get-SPWebTemplatesEnabledForSiteMaster

Advertisements

Get-SPWebTemplatesEnabledForSiteMaster

Get-SPWebTemplatesEnabledForSiteMaster
Site collection templates that are fast site creation enabled
Advertisements

Disable-SPWebTemplateForSiteMaster

Powershell command to disable site template, enabled to create fast site collection is Disable-SPWebTemplateForSiteMaster.

Disable-SPWebTemplateForSiteMaster -Template STS#3
Disable-SPWebTemplateForSiteMaster
Advertisements

Enable-SPWebTemplateForSiteMaster

Powershell command to enable site template for fast site creation is Enable-SPWebTemplateForSiteMaster.

Enable-SPWebTemplateForSiteMaster -Template STS#3
Enable-SPWebTemplateForSiteMaster
Advertisements

New-SPSiteMaster

We can create a new Site Master using a site template by powershell command New-SPSiteMaster.

New-SPSiteMaster -Template STS#3 -ContentDatabase "WSS_Content_44179"
site master dbo.SIteMasters fast site creation sharepoint 2019
Advertisements

Site Master id stored table in content database sql server

SIte master created is actually stored in content database sql server database. We can open sql db, expand the contnet database, expand and identify the table dbo.SiteMasters.

dbo.SiteMasters
Advertisements

Get-SPSiteMaster

This PowerShell cmdlet Get-SPSiteMaster returns a reference to the site master associated with a content database.

Get-SPSiteMaster -ContentDatabase "WSS_Content_44179"
site master associated with content database
Advertisements

Remove-SPSiteMaster

This PowerShell cmdlet Remove-SPSiteMaster deletes site master from content database.

Remove-SPSiteMaster -ContentDatabase "WSS_Content" -Siteid "2a534455-1369-4f1e-bcf9-7e3feaf2a801"
Remove-SPSiteMaster Confirmation
Remove-SPSiteMaster
Advertisements

Fast site creation using powershell in a content database

we can use below powershell command to create fast site using site master present under a content database.

New-SPSite http://win-q2repghf9du:44179/sites/SharePointTech -Template "STS#0" -ContentDatabase "WSS_Content_44179" -OwnerAlias "SPMCSE\Administrator" -CreateFromSiteMaster
create fast site collection New-SPSite
Advertisements
Advertisements

create add a content database in sharepoint 2019

create add a content database is the most common and frequent task in sharepoint 2019 for an administrator. Tasks during sharepoint migration, database upgrade, back up restore of content database, admin follows one of task to add a content database in web application. We can follow manual process of from sharepoint central admin UI method or by using powershell. So in this post will discuss how to create content database.

Advertisements

add a content database in sharepoint using UI method

Follow the step by step procedure to add a content database to web application.

  • Open sharepoint central admin.
  • Click on “Application Management” from left navigation.
  • Click on “Manage content databases” present under “Database”.
manaage content databases in shaarepoint 2019
Advertisements
  • Click on “Add a content database”.
Add a content database in sharepoint 2019
Advertisements
  • Enter “Database Server” name.
  • Enter “Database Name” present under “Database Name and Authentication”.
  • Enter “Number of sites before a warning event is generated”. Once number of sites reached to this number, will send warning mail to admin.
  • Enter “Maximum number of sites that can be created in this database”. This would be the maximum number of site collections can be created. Finally click on “OK”.
database capacity settings database name
Advertisements
  • Content databse is created and available in sql db server as below.
content database in sql database server
Advertisements
content database added to web application
Advertisements

create content database in sharepoint using powershell

We can use powershell command to add a content database instead of following multiple options from central admin. Run the powershell cmdlet New-SPContentDatabase as below to add a new content database.

New-SPContentDatabase "WSS_Content_9999" -DatabaseServer "WIN-56R9D2TBFOB" -WebApplication http://win-56r9d2tbfob:39760/ -MaxSiteCount 20 -WarningSiteCount 19
adding content database to web application using powershell
Advertisements
Advertisements
Advertisements