BLOG > ARTICLE

SharePoint health check (2): Extracting Customizations

4 min read

Blog Header Developer

This post is the second of a series explaining how to audit your SharePoint farm.

Extracting Customizations from the Farm

PowerShellWhen auditing the customizations of your SharePoint farm, the first step is to retrieve all of them in their currently deployed versions.

This can be achieved by some PowerShell code executed on one of the farms servers.

  1. Log in to one of your server on your SharePoint farm (you will require farm administrator permissions)
  2. Create a local folder to store the customizations.
  3. Open a SharePoint Management Shell (PowerShell) window and browse to that new folder.
  4. Extract all WSPs and/or Apps from SharePoint by running the following PowerShell scripts
    • Full trust farm solutions
    • Sandboxed solutions (from a single site)
    • SharePoint Apps (from a single web)
  5. Copy the folder with your customizations to a network share, which is accessible from where you run SPCAF

I want them all!

The code above just illustrates how to get solutions and apps from a single instance of a site or web.

To extract all code customizations from the farm you can use the following complete script. It retrieves them from all sites and webs which are accessible by the account executing the script.

It creates a folder named after the current date, subfolders for full trust solutions, sandboxed solutions and apps as well as subfolders for each site or web that contains a customisation.

folderstructure
Folder structure

During execution it logs the processed sites, solutions and apps.

Without further ado, her comes the complete script

The entire script can be downloaded from GitHub

Great, what now?

Now that you have extracted all code customizations you might wonder what to do with them.

» Read on at “SharePoint health check (3): Auditing Customizations”

Matthias Einig

Matthias is a SharePoint Server MVP and the CEO of Rencore. Working as a SharePoint developer and architect since 2005 he and his colleagues realized the tooling gaps in the SharePoint Application Lifecycle Management process and created several OpenSource projects eg. the SharePoint Software Factory and the SharePoint Solution Deployer, which eventually led to the creation of SPCop and SPCAF. Matthias is speaking at many conferences and community events all over the world and is one of the organizers of SharePoint Saturday Stockholm, SharePoint Saturday Munich and the European Collaboration Summit.