Scenario/Problem: You need to remove a solution from the SharePoint farm.
Solution: Use the Remove-SPSolution
cmdlet with a solution variable.
The Remove-SPSolution
cmdlet enables you to remove a specific solution from the current farm. Use this in conjunction with the Get-SPSolution
cmdlet (explained in a previous section), as shown in Listing 9.9.
$solution = Get-SPSolution
-Identity c0e31dec-294d-4f2d-9ae4-f2e637c766bd
Remove-SPSolution $solution
Note
You may not remove a solution that has been deployed. You must first retract the solution and then perform the removal operation.
18.217.194.39