Using powershell how to get active features and custom features also in a sharepoint farm
-
08-10-2020 - |
Question
How to get all out of the box active features and custom farm solutions features using powershell code in sharepoint 2010 and sharepoint 2013.
Solution
To show all the features on the farm listed by display name and sorted use this:
`Get-SPFeature | Sort -Property DisplayName'
To see all features for a Web Application:
Get-SPFeature -WebApplication http://webapplication
To see all features for a Site Collection:
Get-SPFeature -Site http://sitecollection To see all features for a Site:
Get-SPFeature -Web http://siteurl
SharePoint 2010 Powershell Feature Cmdlets
Here is a snippet of Windows PowerShell code to list all the activated Features for a site collection (SPSite):
Get-SPSite http://sharepoint2010 | % {
$results = @()
Get-SPFeature -Site $_ -Limit All | % {
$feature = $_;
$featuresDefn = (Get-SPFarm).FeatureDefinitions[$_.ID];
$cc = [System.Globalization.CultureInfo]::CurrentCulture;
$obj = New-Object PSObject;
$obj | Add-Member NoteProperty Title $($featuresDefn.GetTitle($cc));
$obj | Add-Member NoteProperty Hidden $($feature.Hidden);
$results += $obj;
}
$results | FT -auto;
}
Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange