Backup-SPEnterpriseSearchServiceApplicationIndex
將搜尋索引備份至指定的備份位置。
Syntax
Backup-SPEnterpriseSearchServiceApplicationIndex
[-Phase] <Int32>
[-SearchApplication] <SearchServiceApplication>
[-BackupFolder] <String>
[-BackupHandleFile] <String>
[[-Retries] <Int32>]
[-AssignmentCollection <SPAssignmentCollection>]
[-Confirm]
[-WhatIf]
[-PeerToPeer]
[-SpecifiedBackupHandle <String>]
[<CommonParameters>]
Backup-SPEnterpriseSearchServiceApplicationIndex
[-SearchApplication] <SearchServiceApplication>
[-BackupHandleFile] <String>
[[-Retries] <Int32>]
[-AssignmentCollection <SPAssignmentCollection>]
[-Confirm]
[-WhatIf]
[-Abort]
[-PeerToPeer]
[-SpecifiedBackupHandle <String>]
[<CommonParameters>]
Description
此 Cmdlet 會將搜尋索引備份至指定的備份位置。 您必須分兩個階段執行此 Cmdlet。 階段一會針對執行備份 Cmdlet 時,將索引中所含的內容,進行備份。 階段二會針對第一階段索引備份開始之後,將新增至索引的內容,進行差異備份。
如需適用於 SharePoint 產品的 Windows PowerShell 權限及最新資訊,請參閱線上文件 SharePoint Server Cmdlet。
範例
------------------範例 1------------------
$ssa = Get-SPEnterpriseSearchServiceApplication
Backup-SPEnterpriseSearchServiceApplicationIndex -Phase 1 -SearchApplication $ssa -BackupFolder "\\backuphost\backupfolder" -BackupHandleFile "\\backuphost\backupfolder\backuphandle.txt" -Retries 3
此範例會開始預設搜尋應用程式之搜尋索引的Phase 1 備份,並將此備份儲存至 \\backuphost\backupfolder 位置。 而 Cmdlet 則會儲存第二階段 Cmdlet 所使用的控制代碼檔案 backuphandle.txt。
------------------範例 2------------------
$ssa = Get-SPEnterpriseSearchServiceApplication
Backup-SPEnterpriseSearchServiceApplicationIndex -Phase 1 $ssa -BackupFolder "\\backuphost\backupfolder" -BackupHandleFile "\\backuphost\backupfolder\backuphandle.txt" -Retries 3
此範例會重新執行階段 1 的 Cmdlet,以檢查備份狀態和進度。
------------------範例 3------------------
$ssa = Get-SPEnterpriseSearchServiceApplication
Backup-SPEnterpriseSearchServiceApplicationIndex -Phase 2 -SearchApplication $ssa -BackupFolder "\\backuphost\backupfolder" -BackupHandleFile "\\backuphost\backupfolder\backuphandle.txt" -Retries 3
此範例會使用階段 1 所用的相同備份位置和備份控制代碼檔案,以開始階段 2 的搜尋索引備份。 您必須先暫停 Search Service 應用程式,才能開始第二階段。
參數
-Abort
{{填入中止描述}}
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-AssignmentCollection
管理物件以適當處置它們。 使用 SPWeb 或 SPSite 等物件可能會耗用大量的記憶體,因此在 Windows PowerShell 指令碼中使用這些物件時,必須適當地管理記憶體。 您可以使用 SPAssignment 物件將物件指派給變數,並在不需要時處置這些物件,以釋放記憶體。 使用 SPWeb、SPSite 或 SPSiteAdministration 物件時,若未使用指派集合或 Global 參數,將會自動處置這些物件。
使用 Global 參數時,所有物件會包含在全域儲存區內。 若未立即使用物件,或未使用 Stop-SPAssignment 命令處置物件,將會發生記憶體不足的狀況。
Type: | SPAssignmentCollection |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-BackupFolder
應寫入之備份檔案的完整 UNC 路徑。
Type: | String |
Position: | 3 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-BackupHandleFile
指定進行中備份工作的檔案控制代碼。
Type: | String |
Position: | 4 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-Confirm
在執行命令之前,提示您確認操作。
如需詳細資訊,請輸入下列命令:get-help about_commonparameters
。
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-PeerToPeer
{{填入 PeerToPeer 描述}}
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-Phase
指定備份工作的階段。
Type: | Int32 |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-Retries
發生暫時性錯誤時的重試次數。
Type: | Int32 |
Position: | 5 |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-SearchApplication
要備份之 Search Service 應用程式的名稱。
Type: | SearchServiceApplication |
Position: | 2 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-SpecifiedBackupHandle
{{Fill SpecifiedBackupHandle Description}}
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |
-WhatIf
顯示訊息會描述命令的功效而不執行命令。
如需詳細資訊,請輸入下列命令:get-help about_commonparameters
。
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Applies to: | SharePoint Server Subscription Edition |