Stsadm 與 Microsoft PowerShell mapping in SharePoint Server 中
適用於:2013 Subscription Edition SharePoint in Microsoft 365
在 Stsadm 作業與 PowerShell Cmdlet 之間沒有一對一的對應時,數據表會列出您必須用來取得類似功能的特定 PowerShell 參數。
Stsadm 作業 | Windows PowerShell Cmdlet |
Activatefeature | Enable-SPFeature |
Activateformtemplate | Enable-SPInfoPathFormTemplate |
Addalternatedomain | New-SPAlternateUrl |
Addcontentdb | Mount-SPContentDatabaseNew-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 參數。 |
驗證 | Set-SPWebApplication 使用 AuthenticationMethod 或 AuthenticationProvider 參數。 |
備份 | Backup-SPConfigurationDatabaseBackup-SPFarmBackup-SPSite |
Backuphistory | Get-SPBackupHistory |
Binddrservice | 無 |
Blockedfilelist | 無 |
Canceldeployment | 無 |
Changepermissionpolicy | 無 |
Copyappbincontent | Install-SPApplicationContent |
Createadminvs | New-SPCentralAdministration |
Creategroup | 無 |
Createsite | New-SPSite |
Createsiteinnewdb | New-SPSite 使用 ContentDatabase 參數。 New-SPContentDatabase |
Createweb | New-SPWeb |
Databaserepair | 使用 Get-SPContentDatabaseOrphanedData 偵測孤立的數據,但請注意,它不會修復孤立的數據。 |
Deactivatefeature | Disable-SPFeature |
Deactivateformtemplate | Disable-SPInfoPathFormTemplate |
Deleteadminvs | Remove-SPCentralAdministration |
Deletealternatedomain | Remove-SPAlternateUrl |
Deleteconfigdb | Disconnect-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 |
電子郵件 | 使用 Set-SPWebApplication 搭配 -SMTPServer 參數集。 |
Enablessc | 無 |
Enumallwebs | Get-SPContentDatabaseOrphanedData |
Enumalternatedomains | Get-SPAlternateURL |
Enumcontentdbs | Get-SPContentDatabase |
Enumdataconnectionfiledependants | Get-SPDataConnectionFileDependent |
Enumdataconnectionfiles | Get-SPDataConnectionFile |
列舉部署 | 無 |
Enumexemptuseragents | Get-SPInfoPathUserAgent |
列舉範本 | Get-SPInfoPathFormTemplate |
列舉群組 | 無 |
列舉 | 無 |
列舉服務 | Get-SPServiceInstance |
列舉 | Get-SPSiteAdministration (若要執行此 Cmdlet,您必須是伺服器陣列管理員群組的成員。) Get-SPSite (若要執行此 Cmdlet,您必須是安裝 SharePoint Server 之電腦上的本機系統管理員。) |
列舉 | Get-SPSolution |
Enumsubwebs | Get-SPWeb |
列舉範本 | Get-SPWebTemplate |
列舉值 | 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 屬性 |
Get-SPDataConnectionFile 使用下列語法: Get-SPDataConnectionFile| where {$_.Name -eq "dataConFileName"}| format-list |
Getformtemplateproperty 屬性 |
Get-SPInfoPathFormTemplate 使用下列語法: Get-SPInfoPathFormTemplate| where {$_.DisplayName -eq "formTemplateName"}| format-list |
Getosearchsetting | 無 |
Getproperty | Get-SPFarmConfigGet-SPTimerJobDisable-SPTimerJobEnable-SPTimerJobSet-SPTimerJobStart-SPTimerJob |
Getsitelock | Get-SPSiteAdministration |
Getsiteuseraccountdirectorypath | 使用 Get-SPSite 取得網站對象,然後輸出 UserAccountDirectoryPath 屬性。 |
Geturlzone | Get-SPAlternateURL |
Import | Import-SPWeb |
Installfeature | Install-SPFeature |
Listlogginglevels | Get-SPLogLevel |
Listqueryprocessoroptions | 無 |
Listregisteredsecuritytrimmers | Get-SPEnterpriseSearchSecurityTrimmer |
Localupgradestatus | 無。 不過, Get-SPPendingUpgradeActions 會提供類似的資訊。 |
Managepermissionpolicylevel | 無 |
Mergecontentdbs | Move-SPSite |
Migrateuser | Move-SPUser |
Osearch | 若是 Osearch 參數 farmcontactemail、farmperformancelevel、farmserviceaccount 及 farmservicepassword,請使用 Get-SPEnterpriseSearchService 和 Set-SPEnterpriseSearchService Cmdlet。 若是 Osearch 參數 start 和 stop,請分別使用 Start-SPEnterpriseSearchServiceInstance 和 Stop-SPEnterpriseSearchServiceInstance Cmdlet。 若是 Osearch 參數 defaultindexlocation,請使用 Get-SPEnterpriseSearchServiceInstance Cmdlet。 |
Osearchdiacriticsensitive | 使用 Get-SPEnterpriseSearchServiceApplication Cmdlet 擷取特定 Search Service 應用程式,然後從 Set-SPEnterpriseSearchServiceApplication Cmdlet 使用 DiacriticSensitive 參數。 |
Profilechangelog | 無。 不過,如果您將共用服務提供者 (SSP) 名稱取代為服務應用程式 (SA) 名稱,則可以使用 Stsadm profilechangelog 作業: stsadm -o profilechangelog-title <SA name>-daysofhistory <number of days>-generateanniversaries |
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-SPFarmRestore-SPSite |
Retractsolution | Uninstall-SPSolution |
Retractwppack | 無 |
Runcontentdeploymentjob | Start-SPContentDeploymentJob |
Scanforfeatures | Install-SPFeature 使用 Scanforfeatures 參數。 |
Setadminport | Set-SPCentralAdministration |
Setapppassword | Set-SPApplicationCredentialKeyRemove-SPApplicationCredentialKey |
Setconfigdb | Connect-SPConfigurationDatabase |
Setcontentdeploymentjobschedule | Set-SPContentDeploymentJob |
Setdataconnectionfileproperty | Set-SPDataConnectionFile |
Setformtemplateproperty | Set-SPInfoPathFormTemplate |
Setlogginglevel | Set-SPLogLevel |
Setosearchsetting | 無 |
Setproperty | Set-SPFarmConfigGet-SPTimerJobDisable-SPTimerJobEnable-SPTimerJobSet-SPTimerJobStart-SPTimerJob |
Setqueryprocessoroptions | 無 |
Setsitelock | Set-SPSiteAdministration 使用 LockState 參數。 |
Setsiteuseraccountdirectorypath | Set-SPSite 使用 UserAccountDirectoryPath 參數。 |
Setworkflowconfig | Set-SPWorkflowConfig |
Siteowner | Set-SPSiteAdministration |
同步處理 | Update-SPProfileSyncClear-SPContentDatabaseSyncDataGet-SPContentDatabase (與 -DaysSinceLastProfileSync 參數) |
Syncsolution | Install-SPSolution 使用 Synchronize 參數。 |
Unextendvs | Remove-SPWebApplication |
Uninstallfeature | Uninstall-SPFeature |
Unquiescefarm | 無 |
Unquiesceformtemplate | Start-SPInfoPathFormTemplate |
Unregistersecuritytrimmer | Remove-SPEnterpriseSearchSecurityTrimmer |
Unregisterwsswriter | 無 |
Updateaccountpassword | Set-SPManagedAccount |
Updatealerttemplates | 無 |
Updatefarmcredentials | 無 |
升級 | 無 |
Upgradeformtemplate | Install-SPInfoPathFormTemplate |
Upgradesolution | Update-SPSolution |
Upgradetargetwebapplication | 無 |
Uploadformtemplate | Install-SPInfoPathFormTemplate |
Userrole | Get-SPUserMove-SPUserNew-SPUserRemove-SPUserSet-SPUser |
Verifyformtemplate | Test-SPInfoPathFormTemplate |