SharePoint [Study Notes]-use stsadm installing or uninstalling features

Source: Internet
Author: User

I. installation and deploymentFeature

Before using the stsadm command, refer to this article

SharePoint [Study Notes] -- add stsadm In Path)

The procedure is as follows:

1. Copy the WSP file to the EG: D: \ sp2010 \ WSP \ myfeature. WSP directory specified by the server to be deployed.

2. Enter the Command Prompt window CommandLine (run-> cmd) as Administrator)

3. Add solution:

Stsadm-O addsolution-filename {path \ wspfilename}
(Eg. stsadm-O addsolution-filename D: \ sp2010 \ WSP \ myfeature. WSP)

4. Deployment Solution:

Stsadm-O deploysolution-name {wspfilename}-URL {siteurl}-allowgacdeployment-immediate
(Eg. stsadm-O deploysolution-name myfeature. WSP-URL http: // myserver-Sp1: 2010-allowgacdeployment-immediate)

If the feature scope is not "Web", do not use the '-URL {siteurl}' parameter above.

5. Go to the website set where the feature you just deployed resides (eg: http: // myserver-Sp1: 2010)

Site actions menu à site settings à site collection administration à site collection features, find the feature you just deployed, and Click Activate to activate it. Then you can use this website set or its sub-sites in a centralized manner.

Ii. RemoveFeature

The following two steps are required:

1. stsadm-O retractsolution-name {wspfilename}
(Eg. stsadm-O retractsolution-name myfeature. WSP)

2. stsadm-O deletesolution-name {wspfilename}
(Eg. stsadm-O deletesolution-name myfeature. WSP)

It can also be implemented through the SharePoint user interface:

Central Administration --> system settings --> Farm Management --> Manage farm solutions --> select the solution you want to operate --> click 'retract solution' at the top of the interface --> wait for a moment, after this operation is complete --> click 'remove solution' at the top of the interface '. This removes the feature you want to remove.

To verify whether you have actually removed your feature, you can go to the website set you are operating on: site actions --> galleries à solutions to check whether the feature exists.

You can also choose siteactions> site collection administration> site collection features to check whether the feature is in.

 

Iii. CommonStsadm commands

1. Add the solution
Stsadm-O addsolution-filename {wspfilename}

2. Deploy the solution
Stsadm-O deploysolution-name {wspfilename}-URL {siteurl}

3. Install the feature
Stsadm-O installfeature-filename {featurefolder} \ feature. xml

4. Activate the feature
Stsadm-O activatefeature-ID {featureid}-URL {siteurl}-Force

5. deactive the feature
Stsadm.exe-O deactivatefeature-filename "c: \ Program Files \ common files \ microsoft shared \ Web Server Extensions \ 14 \ template \ Features \ myfeature \ feature. XML "-ur http: // myserver-SP1: 2010/

6. Uninstall the feature
Stsadm-O uninstallfeature-filename

7. Retract Solution
Stsadm-O retractsolution-name [-url] [-allcontenturls] [-time] [-immediate]

8. Delete Solution
Stsadm-O deletesolution-name

After you deploy the specified feature on a server of SharePoint farm, the sptimer service automatically synchronise/deploy (synchronous/deployment) The solution to other servers in the farm.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.