Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

As part of a migration from SharePoint 2007 to 2010, I am cleaning up old features that are no longer used and/or would have compatibility issues with the upgrade - mainly the old FAB40 templates. To do this cleanly, I am following the instructions from this blog post - deactivating and then deleting the feature before then retracting and removing the solution. By doing the first two steps I can ensure that I am not using the feature somewhere in the farm still, which would otherwise create issues with missing content.

However, it isn't always clear what features are part of a solution. Is there a way to get a list of features used, or deployed with, each solution package?

share|improve this question

2 Answers 2

up vote 1 down vote accepted

I'm assuming you are doing this in your 2007 environment before you upgrade. I'm not sure if there is an easier way such as quering the database or an stsadm command, but this should help.

  1. This code will export the solutions installed in the farm as WSP files.

    SPSolutionCollection solutions = SPFarm.Local.Solutions;
    foreach (SPSolution solution in solutions)
    {
        solution.SolutionFile.SaveAs(solution.SolutionFile.Name);
    }
    
  2. Rename the exported WSP files to add a ".cab" extension

  3. Extract all the files from .cab file

  4. Browse the extracted files to see which features are part of the solution

share|improve this answer
    
I was able to download all of the WSP files for the FAB40 templates from Microsoft. However, when examining them they do not appear to have any folders similar to those in the 12\TEMPLATE\FEATURES folder. Folders inside the WSPs include language definitions but also a Features folder containing onet.xml - which appears to contain references to required features. –  KingJ Dec 2 '11 at 16:27
    
Open the Manifest.xml file from the extracted WSP and look for the <FeatureManifests> element. You will see for example <FeatureManifest Location="AssetTrackingAssetsList\feature.xml"/>, which the solution will automatically deploy this feature to the 12\template\features folder. –  MLF Dec 2 '11 at 17:11
    
That's exactly what i'm after. Now I can cleanly remove these features, many thanks. –  KingJ Dec 6 '11 at 15:40

I guess if you are not decompiling, or have the source, you have to ask the Author.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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