Log Shipping Content Databases in SP2010 and refreshing the listing of site collections
Published Feb 08 2019 12:46 PM 221 Views
Microsoft

First published on MSDN on Aug 26, 2011

There seems to be a little bit of confusion about what happens to your sites tables/listing of sites when you're log shipping content databases in SharePoint 2010. Let's imagine this scenario. Let's say you create a site collection in your production/live farm. The site provisioning process creates an entry in the sites table in your config DB. The next time the logs get shipped, the site collection will be in the content database in your standby farm. Since you're not log shipping the config DB (it's unsupported) you won't get an entry for your new site in your standby farm. Many places say that you need to detach and reattach your content databases in your standby farm. While this will work, it's not true. You can use PowerShell to make this happen automatically. You could also access the RefreshSitesInConfigurationDatabase method with the SharePoint OM if you want as well.

$db = Get-SPDatabase | where {$_.Name -eq "DatabaseName"}
$db.RefreshSitesInConfigurationDatabase()

Version history
Last update:
‎Apr 28 2020 12:03 PM
Updated by: