Сопоставление STSADM Microsoft PowerShell в SharePoint Server

 

**Применимо к:**SharePoint Foundation 2013, SharePoint Server 2013 Enterprise, SharePoint Server 2013 Standard, SharePoint Server 2016

**Последнее изменение раздела:**2017-08-24

Сводка: Операции Stsadm списков и их параметру PowerShell командлетов.

Если прямое сопоставление между операциями и командлетами отсутствует, в таблице указаны параметры PowerShell, которые необходимо использовать для достижения аналогичных функциональных возможностей.

Операция Stsadm

Командлет Windows PowerShell

Activatefeature

Enable-SPFeature

Activateformtemplate

Enable-SPInfoPathFormTemplate

Addalternatedomain

New-SPAlternateUrl

Addcontentdb

Mount-SPContentDatabase

New-SPContentDatabase

Addexemptuseragent

Add-SPInfoPathUserAgent

Addpath

New-SPManagedPath

Addpermissionpolicy

Нет

Addsolution

Add-SPSolution

Addtemplate

Нет

Adduser

New-SPUser

Addwppack

Install-SPWebPartPack

Addzoneurl

New-SPAlternateUrl

Allowuserformwebserviceproxy

Set-SPInfoPathWebServiceProxy

Используйте параметры AllowForUserForms и Identity.

Allowwebserviceproxy

Set-SPInfoPathWebServiceProxy

Используйте параметры AllowWebServiceProxy и Identity.

Authentication

Set-SPWebApplication

Используйте параметр AuthenticationMethod или AuthenticationProvider.

Backup

Backup-SPConfigurationDatabase

Backup-SPFarm

Backup-SPSite

Backuphistory

Get-SPBackupHistory

Binddrservice

Нет

Blockedfilelist

Нет

Canceldeployment

Нет

Changepermissionpolicy

Нет

Copyappbincontent

Нет

Createadminvs

New-SPCentralAdministration

Creategroup

Нет

Createsite

New-SPSite

Createsiteinnewdb

New-SPSite Используйте параметр ContentDatabase.

New-SPContentDatabase

Createweb

New-SPWeb

Databaserepair

Нет

Deactivatefeature

Disable-SPFeature

Deactivateformtemplate

Disable-SPInfoPathFormTemplate

Deleteadminvs

Нет

Deletealternatedomain

Remove-SPAlternateUrl

Deleteconfigdb

Remove-SPConfigurationDatabase

Deletecontentdb

Dismount-SPContentDatabase

Deletegroup

Нет

Deletepath

Remove-SPManagedPath

Deletepermissionpolicy

Нет

Deletesite

Remove-SPSite

Deletesolution

Remove-SPSolution

Deletetemplate

Нет

Deleteuser

Remove-SPUser

Deleteweb

Remove-SPWeb

Deletewppack

Uninstall-SPWebPartPack

Deletezoneurl

Remove-SPAlternateUrl

Deploysolution

Install-SPSolution

Deploywppack

Install-SPWebPartPack

Disablessc

Нет

Displaysolution

Get-SPSolution

Editcontentdeploymentpath

Set-SPContentDeploymentPath

Email

Нет

Enablessc

Нет

Enumalternatedomains

Get-SPAlternateURL

Enumcontentdbs

Get-SPContentDatabase

Enumdataconnectionfiledependants

Get-SPDataConnectionFileDependent

Enumdataconnectionfiles

Get-SPDataConnectionFile

Enumdeployments

Нет

Enumexemptuseragents

Get-SPInfoPathUserAgent

Enumformtemplates

Get-SPInfoPathFormTemplate

Enumgroups

Нет

Enumroles

Нет

Enumservices

Get-SPServiceInstance

Enumsites

Get-SPSiteAdministration (Чтобы выполнить этот командлет, необходимо быть участником группы администраторов фермы.)

Get-SPSite (Для выполнения этого командлета необходимо быть локальным администратором на компьютере, где установлен SharePoint Server ).

Enumsolutions

Get-SPSolution

Enumsubwebs

Get-SPWeb

Enumtemplates

Get-SPWebTemplate

Enumusers

Get-SPUser

Enumwppacks

Get-SPWebPartPack

Enumzoneurls

Get-SPAlternateURL

Execadmsvcjobs

Start-SPAdminJob

Export

Export-SPWeb

Extendvs

New-SPWebApplication

Extendvsinwebfarm

New-SPWebApplicationExtension

Forcedeletelist

Нет

Getadminport

Get-SPWebApplication

Используйте следующий синтаксис:

Get-SPWebApplication -IncludeCentralAdministration | ? {$_.IsAdministrationWebApplication -eq $true}

Getdataconnectionfileproperty property

Get-SPDataConnectionFile

Используйте следующий синтаксис:

Get-SPDataConnectionFile | where {$_.Name -eq "dataConFileName"} | format-list

Getformtemplateproperty property

Get-SPInfoPathFormTemplate

Используйте следующий синтаксис:

Get-SPInfoPathFormTemplate | where {$_.DisplayName -eq "formTemplateName"} | format-list

Getosearchsetting

Нет

Getproperty

Get-SPFarmConfig

Get-SPTimerJob

Disable-SPTimerJob

Enable-SPTimerJob

Set-SPTimerJob

Start-SPTimerJob

Getsitelock

Get-SPSiteAdministration

Getsiteuseraccountdirectorypath

Нет

Geturlzone

Get-SPAlternateURL

Import

Import-SPWeb

Installfeature

Install-SPFeature

Listlogginglevels

Get-SPLogLevel

Listqueryprocessoroptions

Нет

Listregisteredsecuritytrimmers

Get-SPEnterpriseSearchSecurityTrimmer

Localupgradestatus

Нет

Managepermissionpolicylevel

Нет

Mergecontentdbs

Move-SPSite

Migrateuser

Move-SPUser

Osearch

Для применения параметров Osearchfarmcontactemail, farmperformancelevel, farmserviceaccount и farmservicepassword используйте командлеты Get-SPEnterpriseSearchService и Set-SPEnterpriseSearchService.

Для применения параметров Osearch parameters start и stop используйте, соответственно, командлеты Start-SPEnterpriseSearchServiceInstance и Stop-SPEnterpriseSearchServiceInstance.

Для использования параметра Osearch parameter defaultindexlocation используйте командлет Get-SPEnterpriseSearchServiceInstance.

Osearchdiacriticsensitive

Используйте командлет Get-SPEnterpriseSearchServiceApplication для получения определенного приложения-службы поиска, затем используйте параметр DiacriticSensitive из командлета Set-SPEnterpriseSearchServiceApplication.

Profilechangelog

Нет.

Однако можно использовать операцию Stsadm profilechangelog, если необходимо заменить имя поставщика общих служб на имя приложения-службы.

stsadm -o profilechangelog
-title <SA name>
-daysofhistory <number of days>
-generateanniversaries

Дополнительные сведения о приложениях-службах см. в разделе Сведения о службах и приложениях-службах в SharePoint Server.

Provisionservice

Start-SPServiceInstance

Quiescefarm

Нет

Quiescefarmstatus

Нет

Quiesceformtemplate

Stop-SPInfoPathFormTemplate

Reconvertallformtemplates

Update-SPInfoPathFormTemplate

Refreshdms

Нет

Refreshsitedms

Нет

Registersecuritytrimmer

New-SPEnterpriseSearchSecurityTrimmer

Registerwsswriter

Нет

Removedataconnectionfile

Uninstall-SPDataConnectionFile

Removedrservice

Нет

Removeexemptuseragent

Remove-SPInfoPathUserAgent

Removeformtemplate

Uninstall-SPInfoPathFormTemplate

Removesolutiondeploymentlock

Нет

Renameserver

Rename-SPServer

Renamesite

Set-SPSite

Используйте параметр Url.

Renameweb

Set-SPWeb

Используйте параметр RelativeUrl.

Restore

Restore-SPFarm

Restore-SPSite

Retractsolution

Uninstall-SPSolution

Retractwppack

Нет

Runcontentdeploymentjob

Start-SPContentDeploymentJob

Scanforfeatures

Install-SPFeature

Используйте параметр Scanforfeatures.

Setadminport

Set-SPCentralAdministration

Setapppassword

Нет

Setconfigdb

Connect-SPConfigurationDatabase

Setcontentdeploymentjobschedule

Set-SPContentDeploymentJob

Setdataconnectionfileproperty

Set-SPDataConnectionFile

Setformtemplateproperty

Set-SPInfoPathFormTemplate

Setlogginglevel

Set-SPLogLevel

Setosearchsetting

Нет

Setproperty

Set-SPFarmConfig

Get-SPTimerJob

Disable-SPTimerJob

Enable-SPTimerJob

Set-SPTimerJob

Start-SPTimerJob

Setqueryprocessoroptions

Нет

Setsitelock

Set-SPSiteAdministration

Используйте параметр LockState.

Setsiteuseraccountdirectorypath

Get-SPSiteSubscription

New-SPSiteSubscription

Remove-SPSiteSubscription

Setworkflowconfig

Set-SPWorkflowConfig

Siteowner

Set-SPSiteAdministration

Syncsolution

Install-SPSolution

Используйте параметр Synchronize.

Unextendvs

Remove-SPWebApplication

Uninstallfeature

Uninstall-SPFeature

Unquiescefarm

Нет

Unquiesceformtemplate

Start-SPInfoPathFormTemplate

Unregistersecuritytrimmer

Remove-SPEnterpriseSearchSecurityTrimmer

Unregisterwsswriter

Нет

Updateaccountpassword

Set-SPManagedAccount

Updatealerttemplates

Нет

Updatefarmcredentials

Нет

Upgrade

Нет

Upgradeformtemplate

Install-SPInfoPathFormTemplate

Upgradesolution

Update-SPSolution

Upgradetargetwebapplication

Нет

Uploadformtemplate

Install-SPInfoPathFormTemplate

Userrole

Get-SPUser

Move-SPUser

New-SPUser

Remove-SPUser

Set-SPUser

Verifyformtemplate

Test-SPInfoPathFormTemplate

See also

Каталог Microsoft командлетов PowerShell для SharePoint Server