From a8de4f39aa5eec8b92313a67777f7cf0a88c4aed Mon Sep 17 00:00:00 2001 From: Deepayan Bose Date: Wed, 2 Sep 2026 23:07:28 -0700 Subject: [PATCH] docs(ENG-758673) : add updated documentations for other cmdlets and scripts --- .../find-cohesityfilesnapshot.md | 38 +++-- .../find-cohesityobjectsnapshot.md | 29 ++-- .../find-cohesityremotefilesnapshot.md | 44 +++--- .../get-cohesityprotectionjobrun.md | 1 + .../get-cohesityprotectionjobstatus.md | 17 ++- .../new-cohesityprotectionjob.md | 2 +- docs/cmdlets-reference/new-cohesityuser.md | 2 +- ...register-cohesityprotectionsourcehyperv.md | 17 ++- ...gister-cohesityprotectionsourcephysical.md | 4 +- .../cmdlets-reference/restore-cohesityfile.md | 19 +-- .../restore-cohesityfilev2.md | 6 +- .../restore-cohesityoracledatabase.md | 137 +++++++++--------- .../restore-cohesityremotefile.md | 20 +-- .../restore-cohesityremotefilev2.md | 114 ++++++++++----- .../restore-cohesityremotemssqlobject.md | 134 ++++++++--------- .../restore-cohesityremoteoracledatabase.md | 81 ++++++----- .../restore-cohesityvmwarevm.md | 26 +++- .../update-cohesityprotectionjobrun.md | 4 +- 18 files changed, 398 insertions(+), 297 deletions(-) diff --git a/docs/cmdlets-reference/find-cohesityfilesnapshot.md b/docs/cmdlets-reference/find-cohesityfilesnapshot.md index 6bcaf0c4..f0325c2c 100644 --- a/docs/cmdlets-reference/find-cohesityfilesnapshot.md +++ b/docs/cmdlets-reference/find-cohesityfilesnapshot.md @@ -1,15 +1,19 @@ # Find-CohesityFileSnapshot ## SYNOPSIS -Get the information about snapshots that contain the specified file or folder. In addition, information about the file or folder is provided. +Get the information about snapshots that contain the specified file or folder. +In addition, information about the file or folder is provided. ## SYNTAX ``` -Find-CohesityFileSnapshot [-ClusterId ] [-ClusterIncarnationId ] [-FileName ] [-JobId ] - [-SourceId ] [] +Find-CohesityFileSnapshot [[-FileName] ] [-JobId] [-SourceId] [] ``` +## DESCRIPTION +Get the information about snapshots that contain the specified file or folder. +In addition, information about the file or folder is provided. + ## EXAMPLES ### EXAMPLE 1 @@ -17,8 +21,6 @@ Find-CohesityFileSnapshot [-ClusterId ] [-ClusterIncarnationId ] [ Find-CohesityFileSnapshot -FileName "abc.txt" -SourceId 123 -JobId 11 ``` -Returns snapshot information of specified file/folder in metioned source. - ## PARAMETERS ### -FileName @@ -30,15 +32,15 @@ Type: String Parameter Sets: (All) Aliases: -Required: True -Position: Named +Required: False +Position: 1 Default value: None Accept pipeline input: False Accept wildcard characters: False ``` ### -JobId -Specifies the id of the Job that captured the snapshots. +Specifies the name of the Restore Task.Specifies the id of the Job that captured the snapshots. These snapshots are searched for the specified files or folders. This field is required. @@ -48,17 +50,17 @@ Parameter Sets: (All) Aliases: Required: True -Position: Named -Default value: None +Position: 2 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` ### -SourceId Specifies the id of the Protection Source object (such as a VM) to search. -When a Job Run executes, snapshots of the specified Protection Source -object are captured. This operation searches the snapshots of the -object for the file or folder. This field is required. +When a Job Run executes, snapshots of the specified Protection Source object are captured. +This operation searches the snapshots of the object for the file or folder. +This field is required. ```yaml Type: Int64 @@ -66,8 +68,8 @@ Parameter Sets: (All) Aliases: Required: True -Position: Named -Default value: None +Position: 3 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` @@ -79,7 +81,11 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## OUTPUTS -### Cohesity.Model.FileSnapshotInformation +### System.Array ## NOTES +Published by Cohesity ## RELATED LINKS + +[https://cohesity.github.io/cohesity-powershell-module/#/README](https://cohesity.github.io/cohesity-powershell-module/#/README) + diff --git a/docs/cmdlets-reference/find-cohesityobjectsnapshot.md b/docs/cmdlets-reference/find-cohesityobjectsnapshot.md index b85afc99..211e2ff0 100644 --- a/docs/cmdlets-reference/find-cohesityobjectsnapshot.md +++ b/docs/cmdlets-reference/find-cohesityobjectsnapshot.md @@ -1,14 +1,17 @@ # Find-CohesityObjectSnapshot ## SYNOPSIS -List the snapshots for a given object using cohesity v2 REST API. +List the snapshots for a given object. ## SYNTAX ``` -Find-CohesityObjectSnapshot [-ObjectId ] [-JobId ] [] +Find-CohesityObjectSnapshot [-ObjectId] [[-ProtectionGroupIds] ] [] ``` +## DESCRIPTION +List the snapshots for a given object. + ## EXAMPLES ### EXAMPLE 1 @@ -20,7 +23,7 @@ Returns list of snapshot information of specified object with id 12. ### EXAMPLE 2 ``` -Find-CohesityObjectSnapshot -ObjectId 12 -JobId 1111:2222:12 +Find-CohesityObjectSnapshot -ObjectId 12 -ProtectionGroupIds 1111:2222:12 ``` Returns list of snapshot information of specified object with id 12, which is protected through specified protection job. @@ -31,27 +34,28 @@ Returns list of snapshot information of specified object with id 12, which is pr Specifies the id of the Object. ```yaml -Type: Int64 +Type: String Parameter Sets: (All) Aliases: Required: True -Position: Named +Position: 1 Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -JobId -List of protection group id. If specified, this returns only the snapshots of the specified object ID, which belong to the provided protection group IDs. +### -ProtectionGroupIds +List of protection group id. +If specified, this returns only the snapshots of the specified object ID, which belong to the provided protection group IDs. ```yaml -Type: String +Type: String[] Parameter Sets: (All) Aliases: Required: False -Position: Named +Position: 2 Default value: None Accept pipeline input: False Accept wildcard characters: False @@ -64,8 +68,11 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## OUTPUTS -### Cohesity.Model.ObjectSnapshot +### System.Array ## NOTES +Published by Cohesity ## RELATED LINKS -[Read More](https://cohesity.github.io/cohesity-powershell-module/#/README) + +[https://cohesity.github.io/cohesity-powershell-module/#/README](https://cohesity.github.io/cohesity-powershell-module/#/README) + diff --git a/docs/cmdlets-reference/find-cohesityremotefilesnapshot.md b/docs/cmdlets-reference/find-cohesityremotefilesnapshot.md index 896fb32f..df2d54dc 100644 --- a/docs/cmdlets-reference/find-cohesityremotefilesnapshot.md +++ b/docs/cmdlets-reference/find-cohesityremotefilesnapshot.md @@ -1,14 +1,20 @@ # Find-CohesityRemoteFileSnapshot ## SYNOPSIS -Get the information about snapshots from an external target that contain the specified file or folder. In addition, information about the file or folder is provided. +Get the information about snapshots from an external target that contain the specified file or folder. +In addition, information about the file or folder is provided. ## SYNTAX ``` -Find-CohesityRemoteFileSnapshot [-DoNotIncludeIndexedSnapshotsOnly] [-FileName ] [-JobId ][-SourceId ] [] +Find-CohesityRemoteFileSnapshot [[-FileName] ] [-JobId] [-SourceId] + [-DoNotIncludeIndexedSnapshots] [] ``` +## DESCRIPTION +Get the information about snapshots from an external target that contain the specified file or folder. +In addition, information about the file or folder is provided. + ## EXAMPLES ### EXAMPLE 1 @@ -16,15 +22,11 @@ Find-CohesityRemoteFileSnapshot [-DoNotIncludeIndexedSnapshotsOnly] [-FileName < Find-CohesityRemoteFileSnapshot -FileName "abc.txt" -SourceId 123 -JobId 11 ``` -Returns indexed remote snapshot information of specified file/folder in metioned source. - ### EXAMPLE 2 ``` Find-CohesityRemoteFileSnapshot -FileName "abc.txt" -SourceId 123 -JobId 11 -DoNotIncludeIndexedSnapshots ``` -Returns remote snapshot information of specified file/folder in metioned source, that are not indexed. - ## PARAMETERS ### -FileName @@ -36,15 +38,15 @@ Type: String Parameter Sets: (All) Aliases: -Required: True -Position: Named +Required: False +Position: 1 Default value: None Accept pipeline input: False Accept wildcard characters: False ``` ### -JobId -Specifies the id of the Job that captured the snapshots. +Specifies the name of the Restore Task.Specifies the id of the Job that captured the snapshots. These snapshots are searched for the specified files or folders. This field is required. @@ -54,17 +56,17 @@ Parameter Sets: (All) Aliases: Required: True -Position: Named -Default value: None +Position: 2 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` ### -SourceId Specifies the id of the Protection Source object (such as a VM) to search. -When a Job Run executes, snapshots of the specified Protection Source -object are captured. This operation searches the snapshots of the -object for the file or folder. This field is required. +When a Job Run executes, snapshots of the specified Protection Source object are captured. +This operation searches the snapshots of the object for the file or folder. +This field is required. ```yaml Type: Int64 @@ -72,14 +74,15 @@ Parameter Sets: (All) Aliases: Required: True -Position: Named -Default value: None +Position: 3 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` ### -DoNotIncludeIndexedSnapshots -Specifies whether to return indexed snapshots or not. In an indexed snapshot files are guaranteed to exist, while in a non-indexed snapshot files may not exist. +Specifies whether to return indexed snapshots or not. +In an indexed snapshots file are guaranteed to exist, while in a non-indexed snapshots file may not exist. ```yaml Type: SwitchParameter @@ -100,8 +103,11 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## OUTPUTS -### Cohesity.Model.IndexedObjectSnapshot +### System.Array ## NOTES +Published by Cohesity ## RELATED LINKS -[Read More](https://cohesity.github.io/cohesity-powershell-module/#/README) + +[https://cohesity.github.io/cohesity-powershell-module/#/README](https://cohesity.github.io/cohesity-powershell-module/#/README) + diff --git a/docs/cmdlets-reference/get-cohesityprotectionjobrun.md b/docs/cmdlets-reference/get-cohesityprotectionjobrun.md index bf7e12c1..02b471e7 100644 --- a/docs/cmdlets-reference/get-cohesityprotectionjobrun.md +++ b/docs/cmdlets-reference/get-cohesityprotectionjobrun.md @@ -229,6 +229,7 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## OUTPUTS ### System.Array +### System.Object[] ## NOTES Published by Cohesity diff --git a/docs/cmdlets-reference/get-cohesityprotectionjobstatus.md b/docs/cmdlets-reference/get-cohesityprotectionjobstatus.md index 995fe0a4..184eaf36 100644 --- a/docs/cmdlets-reference/get-cohesityprotectionjobstatus.md +++ b/docs/cmdlets-reference/get-cohesityprotectionjobstatus.md @@ -6,7 +6,7 @@ Gets the protection job status. ## SYNTAX ``` -Get-CohesityProtectionJobStatus [] +Get-CohesityProtectionJobStatus [-ReturnObject] [] ``` ## DESCRIPTION @@ -21,6 +21,21 @@ Get-CohesityProtectionJobStatus ## PARAMETERS +### -ReturnObject +Return Output as Object + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: + +Required: False +Position: 2 +Default value: False +Accept pipeline input: False +Accept wildcard characters: False +``` + ### CommonParameters This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). diff --git a/docs/cmdlets-reference/new-cohesityprotectionjob.md b/docs/cmdlets-reference/new-cohesityprotectionjob.md index 0a46b7b5..d127fdae 100644 --- a/docs/cmdlets-reference/new-cohesityprotectionjob.md +++ b/docs/cmdlets-reference/new-cohesityprotectionjob.md @@ -204,7 +204,7 @@ Aliases: Required: False Position: Named -Default value: 4/19/2023 12:34:48 AM +Default value: 9/1/2026 10:08:33 PM Accept pipeline input: False Accept wildcard characters: False ``` diff --git a/docs/cmdlets-reference/new-cohesityuser.md b/docs/cmdlets-reference/new-cohesityuser.md index 54b665a4..37cfe144 100644 --- a/docs/cmdlets-reference/new-cohesityuser.md +++ b/docs/cmdlets-reference/new-cohesityuser.md @@ -143,7 +143,7 @@ Aliases: Required: False Position: Named -Default value: 4/19/2023 12:34:49 AM +Default value: 9/1/2026 10:08:33 PM Accept pipeline input: False Accept wildcard characters: False ``` diff --git a/docs/cmdlets-reference/register-cohesityprotectionsourcehyperv.md b/docs/cmdlets-reference/register-cohesityprotectionsourcehyperv.md index 8a1f1511..0b6cdf6e 100644 --- a/docs/cmdlets-reference/register-cohesityprotectionsourcehyperv.md +++ b/docs/cmdlets-reference/register-cohesityprotectionsourcehyperv.md @@ -8,7 +8,7 @@ The HyperV type can be a SCVMM server or HyperV Host. ``` Register-CohesityProtectionSourceHyperV [-Server] -HyperVType [-Credentials ] - [] + [-ReturnObject] [] ``` ## DESCRIPTION @@ -77,6 +77,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ReturnObject +Set to true, if result need to returned in object format + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: + +Required: False +Position: 2 +Default value: False +Accept pipeline input: False +Accept wildcard characters: False +``` + ### CommonParameters This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). diff --git a/docs/cmdlets-reference/register-cohesityprotectionsourcephysical.md b/docs/cmdlets-reference/register-cohesityprotectionsourcephysical.md index 5aaa21f3..d959484d 100644 --- a/docs/cmdlets-reference/register-cohesityprotectionsourcephysical.md +++ b/docs/cmdlets-reference/register-cohesityprotectionsourcephysical.md @@ -43,13 +43,13 @@ Accept wildcard characters: False Type of host. Must be set to KLinux or KWindows. -Possible values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther +Possible values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther, KSapSybase, KSapMaxDB, KSapSybaseIQ, KDB2, KSapASE, KMariaDB, KPostgreSQL, KVOS, KHPUX ```yaml Type: HostTypeEnum Parameter Sets: (All) Aliases: -Accepted values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther +Accepted values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther, KSapSybase, KSapMaxDB, KSapSybaseIQ, KDB2, KSapASE, KMariaDB, KPostgreSQL, KVOS, KHPUX Required: True Position: Named diff --git a/docs/cmdlets-reference/restore-cohesityfile.md b/docs/cmdlets-reference/restore-cohesityfile.md index 10d9a737..32b7bae3 100644 --- a/docs/cmdlets-reference/restore-cohesityfile.md +++ b/docs/cmdlets-reference/restore-cohesityfile.md @@ -1,7 +1,7 @@ # Restore-CohesityFile ## SYNOPSIS -Restores the specified files or folders. +Restores the specified files or folders from a previous backup. ## SYNTAX @@ -14,7 +14,7 @@ Restore-CohesityFile -TaskName -FileNames -JobId -So ``` ## DESCRIPTION -Request to create a Restore Task for recovering files or folders. +Restores the specified files or folders from a previous backup. ## EXAMPLES @@ -23,21 +23,14 @@ Request to create a Restore Task for recovering files or folders. Restore-CohesityFile -TaskName "restore-file-vm" -FileNames /C/data/file.txt -JobId 1234 -SourceId 843 -TargetSourceId 856 -TargetParentSourceId 828 -TargetHostType KWindows -TargetHostCredential (Get-Credential) ``` -Restores the file from the specified source to the target windows VM from the latest backup. +Restores the specified file to the target windows VM with the source id 856 from the latest backup. ### EXAMPLE 2 ``` -Restore-CohesityFile -TaskName "restore-file-vm" -FileNames /C/data/file.txt -JobId 1234 -JobRunId 3005 -StartTime 1690646467987573 -SourceId 843 -TargetSourceId 856 -TargetParentSourceId 828 -TargetHostType KWindows -TargetHostCredential (Get-Credential) -``` - -Restores the file from the specified source to the target windows VM from the specified snapshot. - -### EXAMPLE 3 -``` Restore-CohesityFile -TaskName "restore-file-physical" -FileNames /C/data/file.txt -JobId 1234 -SourceId 820 -TargetSourceId 858 ``` -Restores the file from the specified source to the target physical server using the latest backup. +Restores the specified file to the target physical server with the source id 858 from the latest backup. ## PARAMETERS @@ -234,13 +227,13 @@ Accept wildcard characters: False Specifies the operating system type of the target host. This is not required when restoring to a Physical Server but must be specified when restoring to a VM. -Possible values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther +Possible values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther, KSapSybase, KSapMaxDB, KSapSybaseIQ, KDB2, KSapASE, KMariaDB, KPostgreSQL, KVOS, KHPUX ```yaml Type: TargetHostTypeEnum Parameter Sets: (All) Aliases: -Accepted values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther +Accepted values: KLinux, KWindows, KAix, KSolaris, KSapHana, KSapOracle, KCockroachDB, KMySQL, KOther, KSapSybase, KSapMaxDB, KSapSybaseIQ, KDB2, KSapASE, KMariaDB, KPostgreSQL, KVOS, KHPUX Required: False Position: Named diff --git a/docs/cmdlets-reference/restore-cohesityfilev2.md b/docs/cmdlets-reference/restore-cohesityfilev2.md index ca2711e1..ddca7673 100644 --- a/docs/cmdlets-reference/restore-cohesityfilev2.md +++ b/docs/cmdlets-reference/restore-cohesityfilev2.md @@ -25,17 +25,17 @@ If the VM files/folders are indexed properly then use the Restore-CohesityFile c ### EXAMPLE 1 ``` -Restore-CohesityFileV2 -sourceVM "SQL-UT-VM2" -targetVM "SQL-UT-VM2" -fileNames "C:\.rnd" -restorePath "C:\" -wait +Restore-CohesityFileV2 -sourceVM "SQL-UT-VM2" -targetVM "SQL-UT-VM2" -fileNames "C:\.rnd" -restorePath "C:\" -wait ``` ### EXAMPLE 2 ``` -Restore-CohesityFileV2 -sourceVM "SQL-UT-VM2" -targetVM "SQL-UT-VMD2" -fileNames "C:\Users\" -restorePath "C:\temp\" -wait +Restore-CohesityFileV2 -sourceVM "SQL-UT-VM2" -targetVM "SQL-UT-VMD2" -fileNames "C:\Users\" -restorePath "C:\temp\" -wait ``` ### EXAMPLE 3 ``` -Restore-CohesityFileV2 -sourceVM "SQL-UT-VM2" -targetVM "SQL-UT-VM2" -fileNames "C:\.rnd" -restorePath "C:\" -taskName "Test_task" -wait +Restore-CohesityFileV2 -sourceVM "SQL-UT-VM2" -targetVM "SQL-UT-VM2" -fileNames "C:\.rnd" -restorePath "C:\" -taskName "Test_task" -wait ``` ## PARAMETERS diff --git a/docs/cmdlets-reference/restore-cohesityoracledatabase.md b/docs/cmdlets-reference/restore-cohesityoracledatabase.md index fd544335..ff8c3f59 100644 --- a/docs/cmdlets-reference/restore-cohesityoracledatabase.md +++ b/docs/cmdlets-reference/restore-cohesityoracledatabase.md @@ -6,11 +6,15 @@ From cluster restores the specified Oracle database from a previous backup. ## SYNTAX ``` -Restore-CohesityOracleDatabase [[-CaptureTailLogs] ] [[-DatabaseFileDestination] ] [[-JobId] ] [[-JobRunId] ] [[-NewDatabaseName] ] [[-NumRedoLogGroup] ] [[-NumTempFiles] ] [[-OracleBase] ] [[-OracleHome] ] [[-RedoLogMemberPath] ] [[-RedoLogSizeInMb] ] [[-RedoLogMemberPrefix] ] [[-SourceDatabaseName] ] [[-SourceName] ] [[-TargetSourceId] ] [[-TaskName] ] [-WhatIf] [-Confirm] [] +Restore-CohesityOracleDatabase [[-TaskName] ] [-SourceName] [-SourceDatabaseName] + [-OracleHome] [-OracleBase] [[-DatabaseFileDestination] ] [-TargetSourceId] + [-JobId] [[-JobRunId] ] [[-CaptureTailLogs] ] [[-NewDatabaseName] ] + [[-NumRedoLogGroup] ] [[-RedoLogMemberPath] ] [[-RedoLogMemberPrefix] ] + [[-RedoLogSizeInMb] ] [[-NumTempFiles] ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION -From cluster restores the specified Oracle database from a latest recoverable or specified backup. +From cluster restores the specified Oracle database from a previous backup. ## EXAMPLES @@ -44,9 +48,8 @@ Restore oracle database "database_1" with mentioned job run id, in the target or ## PARAMETERS -### -CaptureTailLogs -Specifies if the tail logs are to be captured before the restore operation. -This is only applicable if restoring the database to its hosting Protection Source and the database is not being renamed. +### -TaskName +Specifies the name of the restore task. ```yaml Type: String @@ -55,138 +58,140 @@ Aliases: Required: False Position: 1 -Default value: None +Default value: "Restore-Oracle-Object-" + (Get-Date -Format "dddd-MM-dd-yyyy-HH-mm-ss").ToString() Accept pipeline input: False Accept wildcard characters: False ``` -### -DatabaseFileDestination -Location to put the database files(datafiles, logfiles etc.). +### -SourceName +Specifies the source name of the Oracle database to restore. +This can be obtained using Get-CohesityProtectionSource -Environments kOracle. ```yaml Type: String Parameter Sets: (All) Aliases: -Required: False +Required: True Position: 2 -Default value: ORACLE_HOME +Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -JobId -Specifies the job id that backed up this Oracle instance and will be used for this restore. +### -SourceDatabaseName +Specifies a name of the database to recover. ```yaml -Type: Int64 +Type: String Parameter Sets: (All) Aliases: Required: True Position: 3 -Default value: 0 +Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -JobRunId -Specifies the job run id that captured the snapshot for this Oracle instance. -If not specified the latest run is used. -This field must be set if restoring to a different target host. +### -OracleHome +Specifies the Oracle home directory path. ```yaml -Type: Int64 +Type: String Parameter Sets: (All) Aliases: -Required: False +Required: True Position: 4 -Default value: 0 +Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -NewDatabaseName -Specifies a new name for the restored database. +### -OracleBase +Specifies the Oracle base directory path. ```yaml Type: String Parameter Sets: (All) Aliases: -Required: False +Required: True Position: 5 Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -NumRedoLogGroup -Number of redo log groups. +### -DatabaseFileDestination +Location to put the database files(datafiles, logfiles etc.). ```yaml -Type: Long +Type: String Parameter Sets: (All) Aliases: Required: False Position: 6 -Default value: 0 +Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -NumTempFiles -How many tempfiles to use for the recovered database. +### -TargetSourceId +Specifies the id of Oracle source id to restore the database. ```yaml -Type: Long +Type: Int64 Parameter Sets: (All) Aliases: -Required: False +Required: True Position: 7 Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` -### -OracleBase -Specifies the Oracle base directory path. +### -JobId +Specifies the job id that backed up this Oracle instance and will be used for this restore. ```yaml -Type: String +Type: Int64 Parameter Sets: (All) Aliases: Required: True Position: 8 -Default value: None +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` -### -OracleHome -Specifies the Oracle home directory path. +### -JobRunId +Specifies the job run id that captured the snapshot for this Oracle instance. +If not specified the latest run is used. +This field must be set if restoring to a different target host. ```yaml -Type: String +Type: Int64 Parameter Sets: (All) Aliases: -Required: True +Required: False Position: 9 -Default value: None +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` -### -RedoLogMemberPath -List of members of this redo log group. +### -CaptureTailLogs +Specifies if the tail logs are to be captured before the restore operation. +This is only applicable if restoring the database to its hosting Protection Source and the database is not being renamed. ```yaml -Type: String[] +Type: String Parameter Sets: (All) Aliases: @@ -197,11 +202,11 @@ Accept pipeline input: False Accept wildcard characters: False ``` -### -RedoLogSizeInMb -Size of the member in MB. +### -NewDatabaseName +Specifies a new name for the restored database. ```yaml -Type: Long +Type: String Parameter Sets: (All) Aliases: @@ -212,76 +217,76 @@ Accept pipeline input: False Accept wildcard characters: False ``` -### -RedoLogMemberPrefix -Log member name prefix. +### -NumRedoLogGroup +Number of redo log groups. ```yaml -Type: String +Type: Int64 Parameter Sets: (All) Aliases: Required: False Position: 12 -Default value: None +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` -### -SourceDatabaseName -Specifies a name of the database to recover. +### -RedoLogMemberPath +List of members of this redo log group. ```yaml -Type: String +Type: String[] Parameter Sets: (All) Aliases: -Required: True +Required: False Position: 13 Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -SourceName -Specifies the source name of the Oracle database to restore. -This can be obtained using Get-CohesityProtectionSource -Environments kOracle. +### -RedoLogMemberPrefix +Log member name prefix. ```yaml Type: String Parameter Sets: (All) Aliases: -Required: True +Required: False Position: 14 Default value: None Accept pipeline input: False Accept wildcard characters: False ``` -### -TaskName -Specifies the name of the restore task. +### -RedoLogSizeInMb +Size of the member in MB. ```yaml -Type: String +Type: Int64 Parameter Sets: (All) Aliases: Required: False Position: 15 -Default value: "Restore-Oracle-Object-" + (Get-Date -Format "dddd-MM-dd-yyyy-HH-mm-ss").ToString() +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` -### -TargetSourceId -Specifies the id of Oracle source id to restore the database. +### -NumTempFiles +Specifies no. +of tempfiles to be used for the recovered database. ```yaml Type: Int64 Parameter Sets: (All) Aliases: -Required: True +Required: False Position: 16 Default value: 0 Accept pipeline input: False diff --git a/docs/cmdlets-reference/restore-cohesityremotefile.md b/docs/cmdlets-reference/restore-cohesityremotefile.md index a17f64f0..e189b1f2 100644 --- a/docs/cmdlets-reference/restore-cohesityremotefile.md +++ b/docs/cmdlets-reference/restore-cohesityremotefile.md @@ -13,7 +13,7 @@ Restore-CohesityRemoteFile [[-TaskName] ] [-FileNames] [-JobI ``` ## DESCRIPTION -Request to create a Restore Task for recovering files or folders from a remote target. +Restores the specified files or folders from a remote cluster. ## EXAMPLES @@ -22,21 +22,14 @@ Request to create a Restore Task for recovering files or folders from a remote t Restore-CohesityRemoteFile -TaskName "restore-file-vm" -FileNames /C/data/file.txt -JobId 1234 -SourceId 843 -TargetSourceId 856 -TargetParentSourceId 828 -TargetHostCredential (Get-Credential) ``` -Restores the file from the specified source to the target windows VM using the latest backup from remote target. +Restores the specified file to the target windows VM with specified source id from the latest backup. ### EXAMPLE 2 ``` -Restore-CohesityRemoteFile -TaskName "restore-file-vm" -FileNames /C/data/file.txt -JobId 1234 -JobRunId 3005 -StartTime 1690646467987573 -SourceId 843 -TargetSourceId 856 -TargetParentSourceId 828 -TargetHostType KWindows -TargetHostCredential (Get-Credential) -``` - -Restores the file from the specified source to the target windows VM using the specified snapshot from remote target. - -### EXAMPLE 3 -``` -Restore-CohesityRemoteFile -FileNames "/C/myFolder" -NewBaseDirectory "C:\temp\restore" -JobId 61592 -SourceId 3517 -TargetSourceId 3098 +Restore-CohesityRemoteFile -FileNames "/C/myFolder" -NewBaseDirectory "C:\temp\restore" -JobId 61592 -SourceId 3517 -TargetSourceId 3098 ``` -Restores the file from the specified source to the target physical server using the latest backup from remote target. +Restores the specified file to the target physical server with specified source id from the latest backup. ## PARAMETERS @@ -268,8 +261,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## OUTPUTS ## NOTES -This commandlet will be deprecated in future. Please refer and use the commandlet [Restore-CohesityRemoteFileV2](https://cohesity.github.io/cohesity-powershell-module/#/cmdlets-reference/restore-cohesityremotefilev2) instead. +Published by Cohesity. ## RELATED LINKS -[Read More](https://cohesity.github.io/cohesity-powershell-module/#/README) + +[https://cohesity.github.io/cohesity-powershell-module/#/README](https://cohesity.github.io/cohesity-powershell-module/#/README) diff --git a/docs/cmdlets-reference/restore-cohesityremotefilev2.md b/docs/cmdlets-reference/restore-cohesityremotefilev2.md index 63169bb8..c34e971b 100644 --- a/docs/cmdlets-reference/restore-cohesityremotefilev2.md +++ b/docs/cmdlets-reference/restore-cohesityremotefilev2.md @@ -1,19 +1,20 @@ # Restore-CohesityRemoteFileV2 ## SYNOPSIS -Restores the specified files or folders from a previous remote backup based on Cohesity V2 Rest APIs. +Restores the specified files or folders from a remote backup. ## SYNTAX ``` -Restore-CohesityFileV2 [-TaskName ] [-FileName ] [-JobId ] [-SourceId ] - [-TargetSourceId ] [-NewBaseDirectory ] [-SnapshotId ] [-OverwriteExisting] - [-ContinueOnError] [-EncryptionEnabled] [-PreserveAttributes] [-SaveSuccessFiles] [-RecoverMethod ] - [-TargetVMCredential ] [-WhatIf] [-Confirm] [] +Restore-CohesityRemoteFileV2 [-ContinueOnError] [-EncryptionEnabled] [-FileName] [-JobId] + [[-NewBaseDirectory] ] [-OverwriteExisting] [-PreserveAttributes] [[-RecoverMethod] ] + [-SaveSuccessFiles] [[-SnapshotId] ] [-SourceId] [[-TargetSourceId] ] + [[-TargetVMCredential] ] [[-TaskName] ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION -Request to create a task for recovering the specified files or folders from a previous remote backup based on Cohesity V2 Rest APIs. +Restores the specified files or folders from a remote backup. +This commandlet supports only source with environment type VMware/Physical/Isilon. ## EXAMPLES @@ -21,24 +22,29 @@ Request to create a task for recovering the specified files or folders from a pr ``` Restore-CohesityRemoteFileV2 -TaskName "restore-file-vm" -FileName /C/data/file.txt -JobId 1234 -SourceId 843 -TargetSourceId 856 -RestoreMethod AutoDeploy -TargetVMCredential (Get-Credential) ``` + Restores the specified file/folder to the target VM with specified source id from the latest external target backup. ### EXAMPLE 2 ``` -Restore-CohesityRemoteFileV2 -FileName "C:\myFolder\abc.txt" -NewBaseDirectory "C:\temp\restore" -JobId 61592 -SourceId 3517 +Restore-CohesityRemoteFileV2 -FileName "/C/myFolder" -NewBaseDirectory "C:\temp\restore" -JobId 61592 -SourceId 3517 ``` + Restores the specified file/folder in the same server from the latest external target backup. -### EXAMPLE # +### EXAMPLE 3 ``` Restore-CohesityRemoteFileV2 -FileName "/C/myFolder" -NewBaseDirectory "C:\temp\restore" -JobId 61592 -SourceId 3517 -SnapshotId "exchjik" ``` -Restores the specified file/folder in the same server from the specified external target backup.``` + +Restores the specified file/folder in the same server from the specified external target backup. ## PARAMETERS ### -ContinueOnError -Specifies whether to continue recovering other files if one of files or folders failed to recover. +Specifies if the Restore Task should continue even if the restore of some files and folders fails. +If specified, the Restore Task ignores errors and restores as many files and folders as possible. +By default, the Restore Task stops restoring if any operation fails. ```yaml Type: SwitchParameter @@ -68,7 +74,7 @@ Accept wildcard characters: False ``` ### -FileName -Specifies the full name of the files or folders to be restored. +Specifies the full names of the files or folders to be restored. ```yaml Type: String @@ -76,7 +82,7 @@ Parameter Sets: (All) Aliases: Required: True -Position: Named +Position: 1 Default value: None Accept pipeline input: False Accept wildcard characters: False @@ -91,7 +97,7 @@ Parameter Sets: (All) Aliases: Required: True -Position: Named +Position: 2 Default value: 0 Accept pipeline input: False Accept wildcard characters: False @@ -107,14 +113,15 @@ Parameter Sets: (All) Aliases: Required: False -Position: Named -Default value: "/tmp/recover_files_/" + (Get-Date -UFormat "%b_%d_%Y_%I_%M_%p") +Position: 3 +Default value: None Accept pipeline input: False Accept wildcard characters: False ``` ### -OverwriteExisting -Specifies whether to overwrite the existing files. +Specifies that any existing files and folders should not be overwritten during the restore. +By default, value is false. ```yaml Type: SwitchParameter @@ -129,7 +136,8 @@ Accept wildcard characters: False ``` ### -PreserveAttributes -Specifies whether to preserve original attributes. +Specifies that the Restore Task should not preserve the original attributes of the files and folders. +By default, value is false. ```yaml Type: SwitchParameter @@ -145,22 +153,23 @@ Accept wildcard characters: False ### -RecoverMethod Specifies the method to recover files and folders. +Method shoulb be any one of - ExistingAgent, AutoDeploy, VMTools. ```yaml Type: String Parameter Sets: (All) Aliases: -Accepted values: ExistingAgent, AutoDeploy, VMTools Required: False -Position: Named +Position: 4 Default value: ExistingAgent Accept pipeline input: False Accept wildcard characters: False ``` ### -SaveSuccessFiles -Specifies whether to save success files or not. Default value is false. +Specifies whether to save success files or not. +Default value is false. ```yaml Type: SwitchParameter @@ -175,16 +184,17 @@ Accept wildcard characters: False ``` ### -SnapshotId -Specifies the remote snapshot id. +Specifies the snapshot id. +If not specified, the latest remote backup will be used. ```yaml Type: String Parameter Sets: (All) Aliases: -Required: True -Position: Named -Default value: 0 +Required: False +Position: 5 +Default value: None Accept pipeline input: False Accept wildcard characters: False ``` @@ -198,29 +208,30 @@ Parameter Sets: (All) Aliases: Required: True -Position: Named +Position: 6 Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` ### -TargetSourceId -Specifies the id of the target source (such as a VM or Physical server) where the files and folders are to be restored. +Specifies the id of the target source where the files and folders are to be restored. ```yaml Type: Int64 Parameter Sets: (All) Aliases: -Required: True -Position: Named -Default value: None +Required: False +Position: 7 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` ### -TargetVMCredential -Specifies the credentials for the target VM. This is mandatory if the recoverMethod is AutoDeploy or VMTools. +Specifies the credentials for the target VM. +This is mandatory if the recoverMethod is AutoDeploy or VMTools. ```yaml Type: PSCredential @@ -228,7 +239,7 @@ Parameter Sets: (All) Aliases: Required: False -Position: Named +Position: 8 Default value: None Accept pipeline input: False Accept wildcard characters: False @@ -242,13 +253,44 @@ Type: String Parameter Sets: (All) Aliases: -Required: True -Position: Named +Required: False +Position: 9 Default value: "Recover_File_" + (Get-Date -UFormat "%b_%d_%Y_%I_%M_%p") Accept pipeline input: False Accept wildcard characters: False ``` +### -WhatIf +Shows what would happen if the cmdlet runs. +The cmdlet is not run. + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: wi + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -Confirm +Prompts you for confirmation before running the cmdlet. + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: cf + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### CommonParameters This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). @@ -257,7 +299,9 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## OUTPUTS ## NOTES -Currently this commandlet supports only source of environment type either VMware or Physical server or Isilon. +Published by Cohesity. ## RELATED LINKS -[Read More](https://cohesity.github.io/cohesity-powershell-module/#/README) \ No newline at end of file + +[https://cohesity.github.io/cohesity-powershell-module/#/README](https://cohesity.github.io/cohesity-powershell-module/#/README) + diff --git a/docs/cmdlets-reference/restore-cohesityremotemssqlobject.md b/docs/cmdlets-reference/restore-cohesityremotemssqlobject.md index 1ea796ec..8134896a 100644 --- a/docs/cmdlets-reference/restore-cohesityremotemssqlobject.md +++ b/docs/cmdlets-reference/restore-cohesityremotemssqlobject.md @@ -7,29 +7,21 @@ From remote cluster restores the specified MS SQL object from a previous backup. ### Default (Default) ``` -Restore-CohesityRemoteMSSQLObject [-TaskName ] -SourceId -HostSourceId -JobId - [-CaptureTailLogs] [-KeepCDC] [-NewDatabaseName ] [-NewInstanceName ] +Restore-CohesityRemoteMSSQLObject [-TaskName ] [-SourceId ] [-HostSourceId ] + -JobId [-CaptureTailLogs] [-KeepCDC] [-NewDatabaseName ] [-NewInstanceName ] [-RestoreTimeSecs ] [-TargetDataFilesDirectory ] [-TargetLogFilesDirectory ] [-TargetSecondaryDataFilesDirectoryList ] [-DbRestoreOverwritePolicy] [-TargetHostId ] - [-WhatIf] [-Confirm] [] + [-SqlHost ] [-SqlObjectName ] [-TargetHost ] [-WhatIf] [-Confirm] [] ``` ### Jobrun ``` -Restore-CohesityRemoteMSSQLObject [-TaskName ] -SourceId -HostSourceId -JobId - [-JobRunId ] [-StartTime ] [-CaptureTailLogs] [-KeepCDC] [-NewDatabaseName ] - [-NewInstanceName ] [-RestoreTimeSecs ] [-TargetDataFilesDirectory ] - [-TargetLogFilesDirectory ] [-TargetSecondaryDataFilesDirectoryList ] - [-DbRestoreOverwritePolicy] [-TargetHostId ] [-WhatIf] [-Confirm] [] -``` - -### SQL Host -``` -Restore-CohesityRemoteMSSQLObject [-TaskName ] [-SqlHost ] [-SqlObjectName ] [-JobId ] - [-CaptureTailLogs] [-KeepCDC] [-NewDatabaseName ] [-NewInstanceName ] - [-RestoreTimeSecs ] [-TargetDataFilesDirectory ] [-TargetLogFilesDirectory ] - [-TargetSecondaryDataFilesDirectoryList ] [-DbRestoreOverwritePolicy] [-TargetHost ] - [-WhatIf] [-Confirm] [] +Restore-CohesityRemoteMSSQLObject [-TaskName ] [-SourceId ] [-HostSourceId ] + -JobId [-JobRunId ] [-StartTime ] [-CaptureTailLogs] [-KeepCDC] + [-NewDatabaseName ] [-NewInstanceName ] [-RestoreTimeSecs ] + [-TargetDataFilesDirectory ] [-TargetLogFilesDirectory ] + [-TargetSecondaryDataFilesDirectoryList ] [-DbRestoreOverwritePolicy] [-TargetHostId ] + [-SqlHost ] [-SqlObjectName ] [-TargetHost ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -42,7 +34,7 @@ From remote cluster restores the specified MS SQL object from a previous backup. Restore-CohesityRemoteMSSQLObject -SourceId 1279 -HostSourceId 1277 -JobId 31520 -TargetHostId 770 -CaptureTailLogs:$false -NewDatabaseName CohesityDB_r1 -NewInstanceName MSSQLSERVER -TargetDataFilesDirectory "C:\temp" -TargetLogFilesDirectory "C:\temp" -DbRestoreOverwritePolicy:$true ``` -Restore MSSQL database from remote cluster with database id 1279 , database instance id 1277 and job id as 31520 with the latest recoverable snapshot information. +Restore MSSQL database from remote cluster with database id 1279 , database instance id 1277 and job id as 31520 $mssqlObjects = Find-CohesityObjectsForRestore -Environments KSQL Get the source id, $mssqlObjects\[0\].SnapshottedSource.Id Get the source instance id, $mssqlObjects\[0\].SnapshottedSource.SqlProtectionSource.OwnerId @@ -50,12 +42,19 @@ Use the DbRestoreOverwritePolicy:$true for overriding the existing database ### EXAMPLE 2 ``` +Restore-CohesityRemoteMSSQLObject -SqlHost x.x.x.x -JobId 31520 -SqlObjectName instance/databse_1 -TargetHost y.y.y.y -CaptureTailLogs:$false -NewDatabaseName CohesityDB_r1 -NewInstanceName MSSQLSERVER -TargetDataFilesDirectory "C:\temp" -TargetLogFilesDirectory "C:\temp" -DbRestoreOverwritePolicy:$true +``` + +Restore MSSQL database from remote cluster with database name database_1 from the sql host x.x.x.x, and job id as 31520 to the target host y.y.y.y + +### EXAMPLE 3 +``` Restore-CohesityRemoteMSSQLObject -SourceId 3101 -HostSourceId 3099 -JobId 51275 -TargetHostId 3098 -CaptureTailLogs:$false -NewDatabaseName ReportServer_r26 -NewInstanceName MSSQLSERVER -TargetDataFilesDirectory "C:\temp" -TargetLogFilesDirectory "C:\temp" -StartTime 1616956306627994 -JobRunId 60832 -RestoreTimeSecs 1616958037 ``` Request for restore MSSQL object with RestoreTimeSecs (point in time) parameter, StartTime and JobRunId. -### EXAMPLE 3 +### EXAMPLE 4 ``` Restore-CohesityRemoteMSSQLObject -SourceId 3101 -HostSourceId 3099 -JobId 51275 -TargetHostId 3098 -CaptureTailLogs:$false -NewDatabaseName ReportServer_r20 -NewInstanceName MSSQLSERVER -TargetDataFilesDirectory "C:\temp" -TargetLogFilesDirectory "C:\temp" -Confirm:$false -TargetSecondaryDataFilesDirectoryList $patternList ``` @@ -67,13 +66,6 @@ $pattern2 = @{filePattern = "*.ldf"; targetDirectory = "c:\test1"} $patternList += $pattern1 $patternList += $pattern2 -### EXAMPLE 4 -``` -Restore-CohesityRemoteMSSQLObject -SqlHost x.x.x.x -JobId 31520 -SqlObjectName instance/databse_1 -TargetHost y.y.y.y -CaptureTailLogs:$false -NewDatabaseName CohesityDB_r1 -NewInstanceName MSSQLSERVER -TargetDataFilesDirectory "C:\temp" -TargetLogFilesDirectory "C:\temp" -DbRestoreOverwritePolicy:$true -``` - -Restore MSSQL database from remote cluster with database name database_1 from the sql host x.x.x.x, and job id as 31520 to the target host y.y.y.y with latest recoverable snapshot information. - ## PARAMETERS ### -TaskName @@ -233,51 +225,6 @@ Accept pipeline input: False Accept wildcard characters: False ``` -### -SqlHost -Specifies the SQL host from which database need to be restored. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: 0 -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -SqlObjectName -Specifies the name of the SQL Object to be restored. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: 0 -Accept pipeline input: False -Accept wildcard characters: False -``` - -### -TargetHost -Specifies the target host if the application is to be restored to a different host. - -```yaml -Type: String -Parameter Sets: (All) -Aliases: - -Required: False -Position: Named -Default value: 0 -Accept pipeline input: False -Accept wildcard characters: False -``` - ### -RestoreTimeSecs Specifies the time in the past to which the SQL database needs to be restored. This allows for granular recovery of SQL databases. @@ -383,6 +330,51 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -SqlHost +Specifies the SQL Host information + +```yaml +Type: String +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -SqlObjectName +Specifies the SQL Object Name + +```yaml +Type: String +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + +### -TargetHost +Specifies the target host to restore + +```yaml +Type: String +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -WhatIf Shows what would happen if the cmdlet runs. The cmdlet is not run. diff --git a/docs/cmdlets-reference/restore-cohesityremoteoracledatabase.md b/docs/cmdlets-reference/restore-cohesityremoteoracledatabase.md index d29cd9de..45fc1680 100644 --- a/docs/cmdlets-reference/restore-cohesityremoteoracledatabase.md +++ b/docs/cmdlets-reference/restore-cohesityremoteoracledatabase.md @@ -6,7 +6,12 @@ Restores the specified oracle database from a remote backup. ## SYNTAX ``` -Restore-CohesityRemoteOracleDatabase [[-BCTFilePath] ] [[-DatabaseFileDestination] ] [-EnableArchiveLogMode] [[-DatabaseName] ] [[-JobId] ] [[-NewDatabaseName] ] [-NoFilenameCheck] [[-NumRedoLogGroup] ] [[-NumTempFiles] ] [[-OracleBase] ] [[-OracleHome] ] [[-RedoLogMemberPath] ] [[-RedoLogMemberPrefix] ] [[-RedoLogSizeInMb] ] [[-SnapshotId] ] [[-SourceId] ] [[-TargetSource] ] [[-TargetSourceId] ] [[-TaskName] ] [-WhatIf] [-Confirm] [] +Restore-CohesityRemoteOracleDatabase [[-BCTFilePath] ] [-DatabaseFileDestination] + [-EnableArchiveLogMode] [-DatabaseName] [-JobId] [-NewDatabaseName] + [-NoFilenameCheck] [[-NumRedoLogGroup] ] [[-NumTempFiles] ] [-OracleBase] + [-OracleHome] [[-RedoLogMemberPath] ] [[-RedoLogMemberPrefix] ] + [[-RedoLogSizeInMb] ] [[-SnapshotId] ] [-SourceId] [[-TargetSource] ] + [[-TargetSourceId] ] [[-TaskName] ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -19,25 +24,26 @@ Restores the specified oracle database from a remote backup. Restore-CohesityRemoteOracleDatabase -DatabaseName db_1 -SourceId 3 -OracleHome /u01/app/oracle/product/19c/db_1 -OracleBase /u01/app/oracle/product/ -DatabaseFileDestination /u01/app/oracle/product/19c/db_1 -TargetSourceId 1 -JobId 12 -NewDatabaseName new_db1 -RedoLogMemberPath '/' -NoFilenameCheck -EnableArchiveLogMode -NumRedoLogGroup 3 ``` -Restores the specified oracle database from the remote cluster using latest snapshot, protected by job with id 12, from the source with id 3 to the target oracle source with id 1. With specified restore settings. +Restores the specified oracle database from the remote cluster using latest snapshot, protected by job with id 12, from the source with id 3 to the target oracle source with id 1. +With specified restore settings. To get the source details to be restored, -  $oracleObj = Find-CohesityObjectsForRestore -Environments KOracle -  $DatabaseName = $oracleObj[0].SnapshottedSource.name -  $SourceId = $oracleObj[0].SnapshottedSource.ParentId +$oracleObj = Find-CohesityObjectsForRestore -Environments KOracle +$DatabaseName = $oracleObj\[0\].SnapshottedSource.name +$SourceId = $oracleObj\[0\].SnapshottedSource.ParentId To get the target source detail, where database need to be restored, -  $sourceObj = Get-CohesityProtectionSource -Environments kOracle -  $TargetSourceId = $sourceObj[0].protectionSource.id +$sourceObj = Get-CohesityProtectionSource -Environments kOracle +$TargetSourceId = $sourceObj\[0\].protectionSource.id ### EXAMPLE 2 ``` Restore-CohesityRemoteOracleDatabase -DatabaseName db_1 -SourceName x.x.x.x -OracleHome /u01/app/oracle/product/19c/db_1 -OracleBase /u01/app/oracle/product/ -DatabaseFileDestination /u01/app/oracle/product/19c/db_1 -TargetSource y.y.y.y -JobId 12 -NewDatabaseName new_db1 -SnapshotId abcd ``` -Restores the specified oracle database from the remote cluster using specified snapshot, protected by job with id 12, from the source with id 3 to the target oracle source y.y.y.y. With specified restore settings. +Restores the specified oracle database from the remote cluster using specified snapshot, protected by job with id 12, from the source with id 3 to the target oracle source y.y.y.y. +With specified restore settings. To get the snapshot id for restore, -  $snapshotObj = Find-CohesityObjectSnapshot -Object -  $SnapshotId = $snapshotObj[0].id - +$snapshotObj = Find-CohesityObjectSnapshot -Object \ +$SnapshotId = $snapshotObj\[0\].id ## PARAMETERS @@ -80,14 +86,14 @@ Parameter Sets: (All) Aliases: Required: False -Position: 2 +Position: Named Default value: False Accept pipeline input: False Accept wildcard characters: False ``` ### -DatabaseName -Specifies the job id that backed up this Oracle database. +Specifies name of the database to recover. ```yaml Type: String @@ -95,7 +101,7 @@ Parameter Sets: (All) Aliases: Required: True -Position: 2 +Position: 3 Default value: None Accept pipeline input: False Accept wildcard characters: False @@ -110,7 +116,7 @@ Parameter Sets: (All) Aliases: Required: True -Position: 3 +Position: 4 Default value: 0 Accept pipeline input: False Accept wildcard characters: False @@ -140,7 +146,7 @@ Parameter Sets: (All) Aliases: Required: False -Position: 2 +Position: Named Default value: False Accept pipeline input: False Accept wildcard characters: False @@ -150,7 +156,7 @@ Accept wildcard characters: False Number of redo log groups. ```yaml -Type: Long +Type: Int64 Parameter Sets: (All) Aliases: @@ -162,10 +168,11 @@ Accept wildcard characters: False ``` ### -NumTempFiles -How many tempfiles to use for the recovered database. +Specifies no. +of tempfiles to be used for the recovered database. ```yaml -Type: Long +Type: Int64 Parameter Sets: (All) Aliases: @@ -230,7 +237,7 @@ Parameter Sets: (All) Aliases: Required: False -Position: 12 +Position: 11 Default value: None Accept pipeline input: False Accept wildcard characters: False @@ -240,19 +247,20 @@ Accept wildcard characters: False Size of the member in MB. ```yaml -Type: Long +Type: Int64 Parameter Sets: (All) Aliases: Required: False -Position: 11 -Default value: None +Position: 12 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` ### -SnapshotId -Specifies the snapshot id for this Oracle database. If not specified the latest snapshot will be used to restore. +Specifies the snapshot id for this Oracle database. +If not specified the latest snapshot will be used to restore. ```yaml Type: String @@ -260,8 +268,8 @@ Parameter Sets: (All) Aliases: Required: False -Position: 11 -Default value: Latest Recoverable Snapshot +Position: 13 +Default value: None Accept pipeline input: False Accept wildcard characters: False ``` @@ -270,20 +278,19 @@ Accept wildcard characters: False Specifies id of an oracle source from where database need to be restored. ```yaml -Type: Long +Type: Int64 Parameter Sets: (All) Aliases: Required: True -Position: 13 -Default value: None +Position: 14 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` ### -TargetSource Specifies the name of an alternate Oracle source where database to be restored. -This can be obtained using Get-CohesityProtectionSource -Environments kOracle. ```yaml Type: String @@ -291,7 +298,7 @@ Parameter Sets: (All) Aliases: Required: False -Position: 14 +Position: 15 Default value: None Accept pipeline input: False Accept wildcard characters: False @@ -301,13 +308,13 @@ Accept wildcard characters: False Specifies the id of an alternate Oracle source where database to be restored. ```yaml -Type: Long +Type: Int64 Parameter Sets: (All) Aliases: Required: False -Position: 15 -Default value: None +Position: 16 +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` @@ -321,8 +328,8 @@ Parameter Sets: (All) Aliases: Required: False -Position: 15 -Default value: "Restore-Oracle-Object-" + (Get-Date -Format "dddd-MM-dd-yyyy-HH-mm-ss").ToString() +Position: 17 +Default value: "Recover_Oracle_" + (Get-Date -Format "MMM_dd_yyyy_h_mm_tt").ToString() Accept pipeline input: False Accept wildcard characters: False ``` @@ -366,7 +373,7 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## OUTPUTS ## NOTES -Published by Cohesity +Published by Cohesity. ## RELATED LINKS diff --git a/docs/cmdlets-reference/restore-cohesityvmwarevm.md b/docs/cmdlets-reference/restore-cohesityvmwarevm.md index e3703b7a..732a7ae6 100644 --- a/docs/cmdlets-reference/restore-cohesityvmwarevm.md +++ b/docs/cmdlets-reference/restore-cohesityvmwarevm.md @@ -8,17 +8,17 @@ Restores the specified VMware virtual machine from a previous backup. ### Default (Default) ``` Restore-CohesityVMwareVM -JobId -SourceId [-SourceArchivalId ] [-TaskName ] - [-VmNamePrefix ] [-VmNameSuffix ] [-DisableNetwork] [-PoweredOn] [-DatastoreId ] - [-NetworkId ] [-ResourcePoolId ] [-VmFolderId ] [-NewParentId ] - [] + [-VmNamePrefix ] [-VmNameSuffix ] [-DisableNetwork] [-PoweredOn] [-overwriteExistingVm] + [-DatastoreId ] [-NetworkId ] [-ResourcePoolId ] [-VmFolderId ] + [-NewParentId ] [] ``` ### Jobrun ``` Restore-CohesityVMwareVM -JobId -SourceId [-SourceArchivalId ] [-TaskName ] [-JobRunId ] [-StartTime ] [-VmNamePrefix ] [-VmNameSuffix ] [-DisableNetwork] - [-PoweredOn] [-DatastoreId ] [-NetworkId ] [-ResourcePoolId ] [-VmFolderId ] - [-NewParentId ] [] + [-PoweredOn] [-overwriteExistingVm] [-DatastoreId ] [-NetworkId ] [-ResourcePoolId ] + [-VmFolderId ] [-NewParentId ] [] ``` ## DESCRIPTION @@ -204,6 +204,22 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -overwriteExistingVm +Specifies overwriting the existing VM with the restored VM. +By default, the existing VM is not overwritten. + +```yaml +Type: SwitchParameter +Parameter Sets: (All) +Aliases: + +Required: False +Position: Named +Default value: False +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -DatastoreId Specifies the datastore where the VM should be recovered. This field is mandatory when recovering the VM to a different resource pool or to a different parent source such as vCenter. diff --git a/docs/cmdlets-reference/update-cohesityprotectionjobrun.md b/docs/cmdlets-reference/update-cohesityprotectionjobrun.md index b34c5dc7..4066610e 100644 --- a/docs/cmdlets-reference/update-cohesityprotectionjobrun.md +++ b/docs/cmdlets-reference/update-cohesityprotectionjobrun.md @@ -216,7 +216,7 @@ Aliases: Required: True Position: Named -Default value: None +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ``` @@ -261,7 +261,7 @@ Aliases: Required: True Position: Named -Default value: None +Default value: 0 Accept pipeline input: False Accept wildcard characters: False ```