Deploy farm wsp solution in SharePoint 2010/2013 using PowerShell

This SharePoint tutorial, we will discuss how to deploy farm solution (wsp) in SharePoint 2010/2013 using PowerShell? In SharePoint 2013, using the server object model we can develop SharePoint 2013 farm solutions. Farm solutions like visual web parts, features, event receivers, etc. Deploy wsp SharePoint 2010 using PowerShell.

Deploy farm wsp solution in SharePoint 2010/2013 using PowerShell

Using Visual Studio we can deploy the solution to SharePoint 2010/2013 site by simply Right click -> Deploy. But we will not have a visual studio in any other SharePoint servers like testing or production servers. In those servers, we can deploy SharePoint solutions using PowerShell.

Open the SharePoint 2010 Management Shell. You can get to this by going to Start > All Programs > Microsoft SharePoint 2010 Products > SharePoint 2010 Management Shell.

To add a wsp solution using PowerShell in SharePoint:
Add-SPSolution -LiteralPath C:\MyTestFarmSol.wsp

To deploy the wsp solution using PowerShell in SharePoint:
Install-SPSolution –Identity MyTestFarmSol.wsp –WebApplication http://URL -GACDeployment

To update wsp solution using PowerShell in SharePoint:
Update-SPSolution -Identity MyOldFarmWSP.wsp -LiteralPath C:\MyNewFarm.wsp -GACDeployment

To uninstall wsp solution using PowerShell in SharePoint:
Uninstall-SPSolution –Identity MyTestFarmSol.wsp –WebApplication http://URL

Remove wsp solution using PowerShell in SharePoint:
Remove-SPSolution –Identity MyTestFarmSol.wsp

You may like following SharePoint PowerShell tutorials:

Hope this SharePoint 2010/2013 tutorial helps to deploy SharePoint farm solutions using PowerShell.

Donwload Hub site pdf

Download SharePoint Online Tutorial PDF FREE!

Get update on Webinars, video tutorials, training courses etc.

>