locked
how to fully uninstall site definition feature RRS feed

  • Question

  • Hi,

    ages ago a developer installed a Site Definition feature on our SharePoint site that we never really used. I am currently cleaning up the site and want to remove the feature. I retracted it and removed it through Central Admin, however, when I run test-spcontentdatabase I still get error messages:

    One or more setup files are referenced in the database [our database], but are not installed on the current farm. Please install any feature or solution which contains these files.

    File [Features\BasicWCMLayouts\en-us\zz2_EditMode.css] is referenced [1] times in the database [our database], but is not installed on the current farm. Please install any feature/solution which contains this file.

    I could re-install the feature and it would probably get rid of the error, but I don't want the feature in the site. Am I missing a step in uninstalling it? Why are the references kept in the database after the feature has been retracted and removed?

    Tuesday, February 22, 2011 4:02 AM

Answers

  • The most probable answer to this is that there is still one site remaining that was created with this specific site definition.  You will need to identify that site, migrate it's content off to another site and then delete the site in order to clean this up successfully.

     


    I trust that answers your question...

    Thanks
    C

    http://www.cjvandyk.com/blog
    • Marked as answer by Leoyi Sun Monday, March 7, 2011 7:12 AM
    Wednesday, February 23, 2011 6:41 PM
    Answerer
  • you said about site deifnition, but error message says that some feature is missing (BasicWCMLayouts). Are you sure that site definition file is in this feature? In Sharepoint 2010 you can install onet.xml files within features, but usually they are located in 14/Templates/SiteTemplates. If BasicWCMLayouts feature really contains site definition, then you need to identify the site where this feature is activated. But instead of migrate content, try just to deactivate this feature (as you said that it is not used).

    You can indentfiy the site which contains the feature using object model - for example see gl-activate feature. It iterates through all sites recursively and checks is feature activated on site or not.


    Blog - http://sadomovalex.blogspot.com
    CAML via C# - http://camlex.codeplex.com
    • Marked as answer by Leoyi Sun Monday, March 7, 2011 7:12 AM
    Wednesday, March 2, 2011 10:07 AM

All replies

  • The most probable answer to this is that there is still one site remaining that was created with this specific site definition.  You will need to identify that site, migrate it's content off to another site and then delete the site in order to clean this up successfully.

     


    I trust that answers your question...

    Thanks
    C

    http://www.cjvandyk.com/blog
    • Marked as answer by Leoyi Sun Monday, March 7, 2011 7:12 AM
    Wednesday, February 23, 2011 6:41 PM
    Answerer
  • Any idea how I can identify which Site is running the Site Definition?

    Thanks

    Friday, February 25, 2011 2:45 AM
  • you said about site deifnition, but error message says that some feature is missing (BasicWCMLayouts). Are you sure that site definition file is in this feature? In Sharepoint 2010 you can install onet.xml files within features, but usually they are located in 14/Templates/SiteTemplates. If BasicWCMLayouts feature really contains site definition, then you need to identify the site where this feature is activated. But instead of migrate content, try just to deactivate this feature (as you said that it is not used).

    You can indentfiy the site which contains the feature using object model - for example see gl-activate feature. It iterates through all sites recursively and checks is feature activated on site or not.


    Blog - http://sadomovalex.blogspot.com
    CAML via C# - http://camlex.codeplex.com
    • Marked as answer by Leoyi Sun Monday, March 7, 2011 7:12 AM
    Wednesday, March 2, 2011 10:07 AM