2

Noticed the below error in SharePoint 2013 health analyzer .

In some situations, a content database that is used by Microsoft SharePoint Foundation may become corrupted. The corrupted database may contain orphaned items. For example, a document may not have a parent document library or a list may not have a parent Microsoft SharePoint Foundation Web site. Consequently, you may be unable to create new items with the same URL as the orphaned items, and space in the content database will be consumed unnecessarily.

This reported content database has one large site with 150Gb data and one small orphaned site . This small site size is 4GB.

Clicking on automatic repair is not resolving the issue.

Will the content database become corrupted over a time in production?

Is this some thing risk to application?

How can we resolve this issue with any other approach?

0

Best method is use the Health Analyzer rule to repair it automatically, try to run it multiple time if that fixed the issue.

In other workaround,

  • You can detach the content database from the web application and wait for couple of minutes then re attach it. this process also clear the orphan references.

  • if you know about the Site collection url then it will be easy to delete it from that content database. i will use old school stsadm command, you can run it in sharepoint powershell console.

    stsadm -o enumallwebs -databasename "Database name"

This command will give u all site collection in the database. now you have to remove the orphan site from this database.

stsadm -o deletesite -force -url http://contoso.com/sites/contososubsite11 -databaseserver ds -databasename contentdb1

(or)

stsadm -o deletesite -force -siteid e2a114b8-80c9-41f6-87bf-3feddf2ad9b6 -databaseserver ds -databasename contentdb1

http://netsharepoint.blogspot.com/2013/11/orphans-object-clean-up-in-sharepoint.html

lastly, yes orphan object something will cause the problem during the CU upgrade or migration to next version of SharePoint.

  • Sarvar MVP, thanks for detailed information. I have one doubt --Unless we do patching/upgrade, will this orphaned site cause any harm to application/content database in long run? – kumar Aug 2 '18 at 5:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.