Share one content database and site collection between two separate farms (failover farm)
I had been worked on a Business Intelligence platform project (SharePoint 2013 integrated with MS Reporting service). The working environment has two separate SharePoint farms as fail-over farms and they shared with one common content database (in a windows cluster across two servers and using SQL always on for high availability) and site collection. These two farms have their own configuration database and service application.
I created one site collection in primary farm's server and add the same content database in another farm's server via Central Admin UI,
However, the site collection created in primary farm server were not showing in the second farm's server, and so I try to use powershell to connect the content database again as below:
//Find out the content database ID
Get-SPContentDatabase -WebApplication <Web Application URL>
//Disconnect from the current content database
Dismount-SPContentDatabase <identify> (Note: the id was from last command line)
//Connect to the current content database
Mount-SPContentDatabase "WSS_Content" -DatabaseServer "<SQL Server Instance>" -WebApplication <Web Application URL> -NoB2BSiteUpgrade
After executed above script, I saw the site collection showing in Central Admin in the second farm's server.
This post is part of my project "Implement the Business Intelligence On Premises SharePoint 2013 Portal".
If you want to know more my experiences in an implementation guide for above project, please sign up in here.
Recommend book:
Microsoft SharePoint Online for Office 365: Administering and configuring for the cloud
I created one site collection in primary farm's server and add the same content database in another farm's server via Central Admin UI,
However, the site collection created in primary farm server were not showing in the second farm's server, and so I try to use powershell to connect the content database again as below:
//Find out the content database ID
Get-SPContentDatabase -WebApplication <Web Application URL>
//Disconnect from the current content database
Dismount-SPContentDatabase <identify> (Note: the id was from last command line)
//Connect to the current content database
Mount-SPContentDatabase "WSS_Content" -DatabaseServer "<SQL Server Instance>" -WebApplication <Web Application URL> -NoB2BSiteUpgrade
After executed above script, I saw the site collection showing in Central Admin in the second farm's server.
This post is part of my project "Implement the Business Intelligence On Premises SharePoint 2013 Portal".
If you want to know more my experiences in an implementation guide for above project, please sign up in here.
Recommend book:
Microsoft SharePoint Online for Office 365: Administering and configuring for the cloud
Is this a best practice ?
ReplyDeletewould this be supported in a production environment?
how does it handle writing and reading from both farms...
This seems like a bad idea,I'm going to be looking at SQL log shipping and SQL replication in the next week.
I'll revert back here to send you my findings.
Yes, it's in production, both farm has the same content from their common content DB.
DeleteThis comment has been removed by the author.
ReplyDeleteI guess this also means that both the content db's are out of sync - which basically does not mean by definition of sharing. Is my understanding correct?
ReplyDeleteNo, the both farm share one content DB.
ReplyDelete