Here lately I’ve been looking into doing some cleanup for Nintex related databases in a SharePoint farm, so I thought I would share a short write up I did for a few other folks on the process of moving content in the context of dealing with Nintex content databases.
Taken from : https://community.nintex.com/docs/DOC-1092
First take backups of Nintex and content databases involved
Go to central admin under the Nintex workflow section and pick the databases option.
From here scroll down and check your DB mappings to make sure you know which DB’s will be involved in these changes
Next go back to the Nintex Databases section and create a new blank Nintex DB to use for migration (name ie. Nintex_Content_SiteName)
If you are moving SharePoint content as well, go into Central admin under Manage Content Databases and create a new one there, or you can use PowerShell to create the new SharePoint Content DB and attach it to the farm.
The SharePoint content can be migrated by normal backup-spsite and restore-spsite methods specifying the new Content DB created to make sure the SharePoint info goes to the new DB.
Or this can be done using the Move-SPSite command through PowerShell as well with an IIS RESET as the last step.
Now to migrate the Nintex Workflow info you will need to do a few more steps:
- Stop the web app that contains the Nintex info being moved
- Also stop the SharePoint Timer Service on ALL SharePoint servers in the farm so no actions take place in the background during the move.
- Run the nwadmin -o movedata
command to migrate the content to the new Nintex DB
- Example like: nwadmin -o moveData -Url http://webapplication.caresource.corp/sites/sitename
- Once this command executes you may see errors or other info about the moved workflows. If there are failures you may want to choose the option to roll back the changes.
- Once the command finishes successfully, restart the SharePoint Timer Service and the web application in IIS in order to get everything working correctly again.
- Recheck database mappings in central admin to make sure the items are in the newly created database
- May also want to run NWAdmin.exe -o CleanTaskRedirects [-test]
- Specify the old nintex DB to see if there are any leftover workflows for lazy approvals.
- If not, then remove [-test] from the previous command and it should remove any other info to clear out the old Nintex DB
Again, check your mappings in Central Admin to make sure everything is now separated as it should be and good to go
I hope this helps for anyone that has to go through this process in the future. I’m still learning alot about it myself, so once I’ve had plenty of practice, I may post an updated article as well.
Thanks everyone! -BJ