Presentation is loading. Please wait.

Presentation is loading. Please wait.

You too can be one step closer to having a clean, pristine SharePoint environment! 1 Methods and Solutions for Dealing with Orphaned Sites in a Large Scale.

Similar presentations


Presentation on theme: "You too can be one step closer to having a clean, pristine SharePoint environment! 1 Methods and Solutions for Dealing with Orphaned Sites in a Large Scale."— Presentation transcript:

1 You too can be one step closer to having a clean, pristine SharePoint environment! 1 Methods and Solutions for Dealing with Orphaned Sites in a Large Scale SharePoint Environment PNNL-SA Jason Meaden IT Engineer, PNNL Collaboration Tools and Services

2 Introduction – Our Environment Started out with WSS 2.0 Over 750 sites within the first year Both an internal and an external environment Current site count: Over 3200 sites and subsites within our environment Several very large custom web applications and portals, each with custom webparts, solutions, and tools About 2 TB of data 2

3 Introduction – Our Environment Internal 3 Web Front App Server Index Server SQL

4 Introduction – Our Environment External 4 SharePoint Server SQL

5 Orphaned Sites – What Are They? Orphaned objects are sites and/or site collections that dont have corresponding entries in the configuration database. The orphaned site collection data still exists, but the only way to access it is by detaching its content database from the current web application, and then attaching it to a different web application (one that doesnt have a site collection registered at that URL path.) 5

6 Orphaned Sites – Where Do They Come From? From Microsoft: Site collections typically become orphaned when they are in a content database that is being attached to a Web application, but the Web application already contains a site collection with the same Uniform Resource Locator (URL) path. Because site collections cannot share the same URL path in a Web application, only the first site collection registered in the site map will be accessible. All other site collections that use the same URL path cannot be registered in the site map and are considered orphans. 6

7 Orphaned Sites – How Can You Tell If You Have Them? Signs to watch for: You run the STSADM –o deletesite command and it fails with the error This site does not exist You run the STSADM –o restore command and it fails with a 0x80040E2F error Error messages on the server By running a SQL query 7

8 Orphaned Sites – Things Not To Do Never, ever, under any circumstance, directly edit any of your SharePoint databases. Do not manually update records Do not manually insert records Do not manually delete records Dont do it. Ever. 8

9 Orphaned Sites – Cleanin Em Up The Old School Way (Painful.) Grab the SQL code from here: point-orphans-explained.aspx point-orphans-explained.aspx Open Microsoft SQL Server Management Studio Open up the query, and configure the variables for your environment Execute, and view the results 9

10 Orphaned Sites – Cleanin Em Up The Old School Way (Painful.) Use this method if you dont have SP2 installed Configuration Database Orphans (Easy Ones) Notify users (perform during an outage window) Remove Configuration Database Add the Configuration Database You can use either Central Administration or Stsadm.exe 10

11 Orphaned Sites – Cleanin Em Up The Old School Way (Painful.) Content Database Orphans (The Not Easy one.) Ensure that you have a complete and full backup of *everything* Notify users (again, outage window) Determine if the orphaned sites are accessible or not If they are, make a backup of each of them with the STSADM –o backup command Delete the sites with the STSADM –o deletesite command Detach and re-attach the database 11

12 Orphaned Sites – Cleanin Em Up The Old School Way (Cont.) After re-attaching the database, attempt to find the site again If you find it, delete the site, and detach / re-attach the database. Repeat, until you cant find the orphaned site any more. 12

13 Orphaned Sites – Cleanin Em Up The Old School Way (Cont.) Restore all of the backed up sites using the STSADM –o restore command Run the FindOrphans SQL query again – cross your fingers that all of the orphaned sites are gone If they are? Youre done! If they arent, time to start from the beginning. 13

14 Orphaned Sites – Cleanin Em Up The New School Way (Slightly less painful. Hopefully.) Use this method if youve installed SP2 To delete an orphaned site collection named "http://server_name/sites/site_name", perform the following steps: Use the STSADM –o enumallwebs operation to find the site whose URL matches "/sites/site_name, and look for the inSiteMap attribute among the information returned 14

15 Orphaned Sites – Cleanin Em Up The New School Way Look for sites with an InSiteMap attribute that has a value equal to False. This means the site is orphaned. Use the value of the Id attribute from the matching Site tag and use it as the value of the siteid parameter of the deletesite operation. For example: stsadm -o deletesite -force -siteid e2a114b8-80c9-41f6-87bf-3feddf2ad9b6 - databaseserver DS1 -databasename DB1 Perform this for each orphaned site 15

16 Summary: Use the old method if you dont have SP2 installed Make sure to use the prepare to move command before removing databases if you dont have the Infrastructure Update installed After youve installed SP2, use the new method. Orphaned sites will happen to everyone – but with a bit of patience and knowledge they can be taken care of without too much difficulty! 16

17 Questions? Comments? 17


Download ppt "You too can be one step closer to having a clean, pristine SharePoint environment! 1 Methods and Solutions for Dealing with Orphaned Sites in a Large Scale."

Similar presentations


Ads by Google