SharePoint Solutions – Add, Deploy, Retract and Remove using PowerShell and STSADM

When you want to update a solution, sometimes you can’t retract a solution from Central Admin.

Error messages:
“A feature with ID xxxxxxxxx has already been installed in this farm. Use the force attribute to explicitly re-install the feature.”

Do the following:

1. Use PowerShell to Retract the solution:

Uninstall-SPSolution -Identity solutionName.wsp –WebApplication http://YourSharepointWebApp/

2. Use STSADM to remove the solution:
(Go to the command line (Start – Run – cmd), then go to this path: C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\BIN, then type the following command)

stsadm -o deletesolution -name "solutionName.wsp" -override

3. Use PowerShell to add the solution:

Add-SPSolution -LiteralPath C:\Temp\moving\solutionName.wsp

4. Use PowerShell to deploy the solution (with “-Force” attribute):

Install-SPSolution –Identity CustomerDetails.wsp –WebApplication http://YourSharepointWebApp/ –GACDeployment -Force

Advertisements
This entry was posted in PowerShell, SharePoint 2010, STSADM. Bookmark the permalink.

One Response to SharePoint Solutions – Add, Deploy, Retract and Remove using PowerShell and STSADM

  1. Look here says:

    Hello! I could have sworn I’ve been to this blog before but
    after reading through some of the post I realized it’snew to me.

    Nonetheless, I’m definitely delighted I found it and
    I’ll be book-marking and checking back frequently!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s