split nintex database and sharepoint content database for one to one mapping of nintex and sharepoint content databases. You must be not clear, what is split database ? When nintex workflow installed in default configuration, there will be one database containing all workflow data. By time workflow content grow high which will impact performance. So as to improve performance of workflow for sharepoint site containing nintex workflow, we can move nintex database from default all in one content database to a dedicated nintex database. Moving nintex database to dedicated content database from common db is called split database.
Below is the current condition of site collection and nintex database.
Site Collection : http://win-q2repghf9du/sites/SP2019 Site Collection Content Database (multiple site collections present) : WSS_Content_8888 Nintex Database : Nintex2019 Nintex Database Server : WIN-56R9D2TBFOB
Site Collection : http://win-q2repghf9du/sites/SP2019 Site Collection Content Database (Only 1 site collection) : WSS_Content_9999 Nintex Database : Nintex2019_SP2019 Nintex Database Server : WIN-56R9D2TBFOB
Complete steps we will follow as below.
- Create New Content Database
- Move site collection to dedicate content database
- Create New Nintex Workflow Content Database
- Add service accounts to Nintex Workflow Content Database
- Map SharePoint Content Database to Nintex Workflow Content Database
- Reacivate Nintex workflow Site Collection feature
- nwadmin -o movedata
Create New Content Database
- Add a content database in sharepoint under Manage Content Database option using central admin or powershell.
New-SPContentDatabase "WSS_Content_9999" -DatabaseServer "WIN-56R9D2TBFOB" -WebApplication http://win-q2repghf9du -MaxSiteCount 1 -WarningSiteCount 0
follow the below post to get in detail information on creating new content database in SharePoint.
create add a content database in sharepoint 2019
Map permission between content database
Map or clone permission of new content database, same as the old content database (“WSS_Content_8888” and “WSS_Content_9999”).
Move site collection to dedicate content database
- move site collection to another content database using powershell command Move-SPSite.
Move-SPSite "<Site Collection URL>" -DestinationDatabase "<Database-Name>" Move-SPSite "http://win-q2repghf9du/sites/SP2019" -DestinationDatabase "WSS_Content_9999"
follow the complete process to move site collection to new content database from previous post link mentioned below.
move site collection to dedicate content database
Create New Nintex Workflow Content Database
- Navigate to central admin in SharePoint.
- Click on “Nintex Workflow Management” from left navigation central admin.
- Click on “Database setup” present under “Nintex Workflow Management”.
- Click on “Add content database”.
- Enter “Database Server”, “Database name”.
- Keep the authentication as “Windows authentication”, default recommended option.
- For the option “Service account access” under “Grant service account access”, select “Yes”.
Add service accounts to Nintex Workflow Content Database
- When you will select option “Service account access” under “Grant service account access”, select “Yes”, nintex service accounts will be added to the newly created content database.
- Make sure “App pool Account” has role “WSS_Content_Application_Pools” assigned in “Database Permissions” for new nintex database “Nintex2019_SP2019”.
- You can create ticket with db team for nintex database permissions mapping between old and new nintex databases.
Map SharePoint Content Database to Nintex Workflow Content Database
Next step in nintex database mapping, we need to map the newly created content database or dedicated SharePoint site collection content database, with nintex workflow database created newly. Follow the steps by step procedure.
- Click on “Database Setup” present under “Nintex Workflow Management”.
- Click on “Manage database mappings”.
- Identify the dedicated site collection content database, we created. you will find drop down option side to content database. Select the nintex workflow content database from drop down option for mapping site collection content db with nintex workflow db.
- Click on “OK” to apply changes.
- It will create a connection string.
Reacivate Nintex workflow Site Collection feature
- Navigate to the site collection where workflow data is being moved.
- Deactivate the nintex workflow site collection feature and reactivate.
- Save the changes and perform an IISRESET.
nwadmin -o movedata
use the command MoveData to move nintex database to new database.
- Stop App Pool for the web application “http://win-q2repghf9du”.
- Stop SharePoint Administration and SharePoint Timer Service in all servers in the farm.
start stop manage services in windows server with powershell
- Open sharepoint management console and type the below command to move the nintex database to the newly created nintex database. You need to pass powershell parameter GUID of site collection. Follow the post “Get site collection GUID using powershell” to get siteid details.
Run nwadmin -o movedata, the details for which is below to move nintex workflow data Into new database
NWAdmin.exe -o MoveData [-Url <siteCollectionUrl>] [-SiteID <site GUID>] [-SourceDatabase <connection string>] [-TargetDatabase <connection string>] [-RetainSourceData] NWAdmin.exe -o MoveData [-Url <siteCollectionUrl>] [-SiteID <site GUID>] [-SourceDatabase <Data Source=Source nintex DB server;Initial Catalog=Source/old nintex content DB;Integrated Security=True>] [-TargetDatabase <Data Source=Destination Nintex DB Server;Initial Catalog=Destination/new nintex content DB;Integrated Security=True>] [-RetainSourceData] NWAdmin.exe -o MoveData -Url http://win-q2repghf9du/sites/SP2019 -SiteID dhajdhhh-*******-*******-*******-******* -SourceDatabase "Data Source=WIN-56R9D2TBFOB;Initial Catalog=Nintex2019;Integrated Security=True" -TargetDatabase "Data Source=WIN-56R9D2TBFOB;Initial Catalog=Nintex2019_SP2019;Integrated Security=True"
- After running the command nintex data will be moved to new nintex DB and you will get message in powershell window as below.
Data will be moved for the site collection http://win-q2repghf9du/sites/SP2019 (site collection GUID). Restart each service to continue workflow operation.
- Restart App Pool for the web application “http://win-q2repghf9du/”.
- Start SharePoint Administration and SharePoint Timer Service in all servers in the farm.
- Deactivate the nintex workflow site collection feature and reactivate that make split database activity complete .
Leave a Reply