Chat now with support
Chat mit Support

Rapid Recovery 6.3 - Command Line and Scripting Reference Guide

Rapid Recovery overview and system requirements Command Line Management Utility PowerShell Module
Prerequisites for using PowerShell Working with commands and cmdlets Rapid Recovery PowerShell module cmdlets
Add-CredentialsVaultAccount AddEncryptionKeytoProtectedMachine Add-EsxAutoProtectObjects Add-EsxVirtualMachines Add-HyperVClusterSharedVirtualDisks Add-HyperVClusterVirtualMachines Add-HyperVVirtualMachines Disable-HyperVAutoProtection Edit-ActiveBlockMapping Edit-AzureVirtualStandby Edit-EsxiVirtualStandby Edit-EsxServerProtectionRules Edit-ExcludedFilesAndFolders Edit-HyperVClusterProtectionRules Edit-HyperVServerProtectionRules Edit-HyperVVirtualStandby Edit-OracleDBVerifyNightlyJob Edit-OracleLogTruncationNightlyJob Edit-Replication Edit-ScheduledArchive Edit-VBVirtualStandby Edit-VMVirtualStandby Enable-HyperVAutoProtection Enable-OracleArchiveLogMode Get-ActiveJobs Get-CloudAccounts Get-Clusters Get-CompletedJobs Get-CredentialsVaultAccounts Get-ExchangeMailStores Get-Failed Get-FailedJobs Get-HyperVClusterSharedVirtualDisks Get-ListAzureVMSizes Get-Mounts Get-OracleInstanceMetadata Get-OracleInstances Get-Passed Get-ProtectedServers Get-ProtectionGroups Get-ProtectionRules Get-QueuedJobs Get-RecoveryPoints Get-ReplicatedServers Get-Repositories Get-ScheduledArchives Get-SqlDatabases Get-TransferQueueEntries Get-UnprotectedVolumes Get-Version Get-VirtualizedServers Get-Volumes Join-CredentialsVaultAccount New-AzureVirtualStandby New-Base New-BootCD New-CloudAccount New-EncryptionKey New-EsxiVirtualStandby New-FileSearch New-HyperVVirtualStandby New-Mount New-Replication New-Repository New-ScheduledArchive New-Snapshot New-VBVirtualStandby New-VMVirtualStandby Open-DvmRepository Push-Replication Push-Rollup Remove-Agent Remove-CredentialsVaultAccount Remove-EncryptionKey Remove-EsxAutoProtectObjects Remove-EsxVirtualMachines Remove-HyperVClusterSharedVirtualDisks Remove-HyperVClusterVirtualMachines Remove-HyperVVirtualMachines Remove-Mount Remove-Mounts Remove-RecoveryPoints Remove-Replication Remove-Repository Remove-ScheduledArchive Remove-VirtualStandby Restart-CoreService Resume-Replication Resume-ScheduledArchive Resume-Scheduler Resume-Snapshot Resume-VirtualStandby Set-AgentMetadataCredentials Set-CredentialsVaultAccount Set-DedupCacheConfiguration Set-License Set-OracleMetadataCredentials Set-ReplicationResponse Start-Archive Start-AttachabilityCheck Start-AzureDeploy Start-AzureExport Start-BackupSettings Start-ChecksumCheck Start-ConfigureAgentMigration Start-ConsumeSeedDrive Start-CopySeedDrive Start-EsxiExport Start-HypervExport Start-LogTruncation Start-MountabilityCheck Start-OptimizationJob Start-OracleDBVerifyJob Start-OracleLogTruncationJob Start-Protect Start-ProtectCluster Start-ProtectEsxServer Start-ProtectHyperVCluster Start-ProtectHyperVServer Start-RepositoryCheck Start-RestoreAgent Start-RestoreArchive Start-RestoreSettings Start-RestoreUrc Start-ScheduledArchive Start-VBExport Start-VirtualStandby Start-VMExport Stop-ActiveJobs Stop-CoreService Suspend-Replication Suspend-ScheduledArchive Suspend-Scheduler Suspend-Snapshot Suspend-VirtualStandby Update-Repository
Localization Qualifiers
Scripting

Qualifiers

The following table describes the qualifiers available for Rapid Recovery PowerShell Module.

Table 217: Rapid Recovery PowerShell module qualifiers
Qualifier Usage
-core <Rapid Recovery Core Name>
Host name of the Core.

Default: Localhost

-ProtectedServer <Protected Server Name>
Host name/IP address of the Rapid Recovery Agent.

Default: Localhost if multiple servers protected, otherwise the single server protected.

-Mode <READ, READWRITE, WRITE>
Recovery Point Mount mode.

Default: Read.

-Volumes <Snapshot Volume Letter>
Snapshot volume letter from Rapid Recovery Agent.

Default: All.

-User <User Name>
User name used to connect to the Rapid Recovery Core.

This is typically the service user.

-Domain <Domain Name>
Domain to which the user defined in /User belongs.
-Password <Password>
Password of the user defined in /User.
-Path <Target path to mount, dismount 
recovery points or archive location>
For example: C:\RapidRecoveryMount.

Input Parameters for PowerShell Scripting

All available input parameters are used in sample scripts. The parameters are described in the following tables.

NOTE: Script files must possess the same name as the sample script files.

AgentProtectionStorageConfiguration (namespace Replay.Common.Contracts.Agents)

The following table presents the available objects for the AgentProtectionStorageConfiguration parameter.

Table 218: Objects for the AgentProtectionStorageConfiguration parameter
Method Description
public Guid RepositoryId { get; set; } Gets or sets the ID of the repository where the agent recovery points are stored.
public string EncryptionKeyId { get; set; } Gets or sets the ID of the encryption key for this agent's recovery points. An empty string means no encryption.

AgentTransferConfiguration (namespace Replay.Common.Contracts.Transfer)

The following table presents the available objects for the AgentTransferConfiguration parameter.

Table 219: Objects for the AgentTransferConfiguration parameter
Method Description
public uint MaxConcurrentStreams { get; set; } Gets or sets the maximum number of concurrent TCP connections the Core establishes to the agent for transferring data.
public uint MaxTransferQueueDepth { get; set; } Gets or sets the maximum number of block extents which can be queued for writing. When a range of blocks are read from a transfer stream, that range is placed on a producer or consumer queue, where a consumer thread reads it and writes it to the epoch object. If the repository writes slower than the network reads, this queue fills up. The point at which the queue is full and reads stop is the maximum transfer queue depth.
public uint MaxConcurrentWrites { get; set; } Gets or sets the maximum number of block write operations to have outstanding on an epoch at any given time. If additional blocks are received beyond the maximum number of write operations specified in this parameter, those additional blocks are ignored until one of the outstanding writes finishes.
public ulong MaxSegmentSize { get; set; } Gets or sets the maximum number of contiguous blocks to transfer in a single request. Depending on testing, higher or lower values may be optimal.
public Priority Priority { get; set; } Gets or sets the priority for transfer request.
public uint GetChangedBlocksRetries { get; set; } Gets or sets the count of retries if initial retrieval of changed blocks from the agent failed.
public int MaxRetries { get; set; } Gets or sets the maximum number of times a failed transfer should be retried before it is presumed failed.
public bool UseDefaultMaxRetries { get; set; } If included, the default maximum number of retries (specified in transfer configuration) will be used.
public Guid ProviderId{ get; set; } Gets or sets the GUID of the VSS provider to use for snapshots on this host. Administrators typically accept the default.
public Collection<ExcludedWriter> ExcludedWriterIds { get; set; } Gets or sets the collection of VSS writer IDs that should be excluded from this snapshot. The writer ID is determined by the name of the writer. This name is for documentation purposes only, and does not necessarily provide an exact match of the writer name.
public ushort TransferDataServerPort { get; set; } Gets or sets a value containing the TCP port upon which to accept connections from the Core for the actual transfer of data from the protected machine to the Core. The Agent attempts to listen on this port, but if the port is in use, the protected machine can use a different port instead. The Core should use the port number specified in the BlockHashesUri and BlockDataUri properties of the VolumeSnapshotInfo object for each snapped volume.
public TimeSpan CleanSnapshotTimeout { get; set; } Gets or sets the amount of time to wait for cleaning up the snapshot after transfer is finished.
public TimeSpan SnapshotTimeout { get; set; } Gets or sets the amount of time to wait for a VSS snapshot operation to complete before giving up and timing out.
public TimeSpan TransferTimeout { get; set; } Gets or sets the amount of time to wait for further contact from the Core before abandoning the snapshot.
public TimeSpan NetworkReadTimeout { get; set; } Gets or sets the timeout for network read operations related to this transfer.
public TimeSpan NetworkWriteTimeout { get; set; } Gets or sets the timeout for network write operations related to this transfer.
public uint InitialQueueSize { get; set; } Gets or sets a size of initial queue or requests.
public uint MinVolumeFreeSpacePercents { get; set; } Gets or sets a minimal amount of free space on a volume, measured by percentage. If free space is lower than the amount specified in this parameter, then all change logs are deleted and a base image is forced.
public uint MaxChangeLogsSizePercents { get; set; } Gets or sets a maximum size of driver change logs as part of volume capacity, measured by percentage. If part of change logs is bigger than this value, then all change logs are deleted and a base image is forced.
public bool EnableVerification { get; set; } Gets or sets a value indicating whether diagnostic verification of each block sent to Core should be performed.

BackgroundJobRequest (namespace Replay.Core.Contracts.BackgroundJobs)

The following table presents the available objects for the BackgroundJobRequest parameter.

Table 220: Objects for the BackgroundJobRequest parameter
Method Description
public AgentIdsCollection AgentIds { get; set; } Gets or sets the IDs of the protected machines.
public bool IsNightlyJob { get; set; } Gets or sets the value indicating whether the background job is a nightly job.
public Guid NightlyJobTransactionId { get; set; } Gets or sets the ID of nightly job transaction.
public Guid JobId { get; set; } Gets or sets the ID of background job.
public bool Force { get; set; } Gets or sets the value indicating if a job was forced.
public uint JobStartsCount { get; set; } Gets or sets the number of attempts to start a job.
public virtual bool InvolvesAgentId(Guid agentId) Determines the value indicating whether the concrete agent is involved in job.

ChecksumCheckJobRequest (namespace Replay.Core.Contracts.Exchange.ChecksumChecks)

Inherits its values from the parameter, DatabaseCheckJobRequestBase.

DatabaseCheckJobRequestBase (namespace Replay.Core.Contracts.Exchange)

Inherits its values from the parameter, BackgroundJobRequest.

Table 221: Objects for the DatabaseCheckJobRequestBase parameter
Method Description
public string RecoveryPointId { get; set; } Gets or sets the ID of the recovery point for which databases will be checked.

ExportJobRequest (namespace Replay.Core.Contracts.Export)

Inherits its values from the parameter, BackgroundJobRequest.

The following table presents the available objects for the ExportJobRequest parameter.

Table 222: Objects for the ExportJobRequest parameter
Method Description
public uint RamInMegabytes { get; set; } Gets or sets the memory size for the exported VM. Set to zero (0) to use the memory size of the source machine.
public ushort CpuCount { get; set; } Gets or sets the CPU count for the exported VM. Set to 0 to use the CPU count of the source machine.
public ushort CoresPerCpu { get; set; } Gets or sets the Cores per CPU count for the exported VM. Set to 0 to use the Cores per CPU count of the source machine.
public VirtualMachineLocation Location { get; set; } Gets or sets the target location for this export. This is an abstract base class.
public VolumeImageIdsCollection VolumeImageIds { get; private set; } Gets or sets the volume images to include in the VM export.
public ExportJobPriority Priority { get; set; } Gets or sets the priority for export request.

NightlyAttachabilityJobRequest (namespace Replay.Core.Contracts.Sql)

Inherits its values from the parameter, BackgroundJobRequest.

Table 223: Objects for the NightlyAttachabilityJobRequest parameter
Method Description
public int SimultaneousJobsCount { get; set; } Gets or sets count of jobs that can be run simultaneously.

RollupJobRequest (namespace Replay.Core.Contracts.Rollup)

Inherits its values from the parameter, BackgroundJobRequest.

TakeSnapshotResponse (namespace Replay.Agent.Contracts.Transfer)

The following table presents the available objects for the TakeSnapshotResponse parameter.

Table 224: Objects for the TakeSnapshotResponse parameter
Method Description
public Guid SnapshotSetId { get; set; } Gets or sets the GUID assigned by VSS to this snapshot.
public VolumeSnapshotInfoDictionary VolumeSnapshots { get; set; } Gets or sets the collection of snapshot info for each volume included in the snap.

TransferJobRequest (namespace Replay.Core.Contracts.Transfer)

Inherits its values from the parameter, BackgroundJobRequest.

The following table presents the available objects for the TransferJobRequest parameter.

Table 225: Objects for the TransferJobRequest parameter
Method Description
public VolumeNameCollection VolumeNames { get; set; } Gets or sets the collection of names for transfer.

VolumeNames is a data structure that contains the following data:

  • GuidName. The Guid associated with the volume, used as the name if a DisplayName is not set.
  • DisplayName. The displayed name of the volume.
public VolumeNameCollection TransferredVolumes { get; set; } Gets or sets the collection of transferred volumes.
public VolumeNameCollection DependentVolumeNames { get; set; } Gets or sets the collection of dependent volumes.
public QuotaSettingsCollection EnabledDiskQuotas { get; set; } Gets or sets quotas that are enabled on a volume.
public ShadowCopyType ShadowCopyType { get } Gets the type of copying for transfer. The available values are:
  • Copy
  • Full
public AgentTransferConfiguration TransferConfiguration { get; set; } Gets or sets the transfer configuration.

AgentTransferConfiguration is an object which will have the following data:

  • MaxConcurrentStreams. The maximum number of concurrent TCP connections the core will establish to the agent for transferring data
  • MaxTransferQueueDepth. The maximum number of block extents which can be queued up for writing
  • MaxConcurrentWrites. The maximum number of block write operations to have outstanding on an epoch at any given time. If additional blocks are received when this many block writes are outstanding, those additional blocks will be ignored until one of the outstanding blocks gets written.
  • MaxSegmentSize. The maximum number of contiguous blocks to transfer in a single request
  • Priority. An object which will have the following data:
    • Undefined
    • One
    • Two
    • Three
    • Four
    • Five
    • Six
    • Seven
    • Eight
    • Nine
    • Ten
    • Highest (which is equal to One)
    • Lowest (which is equal to Ten)
    • Default (which is equal to Five)
  • MaxRetries. The maximum number of times a failed transfer should be retried before it is presumed failed
  • UseDefaultMaxRetries. A value indicating that the maximum number of retries is the default value
  • ProviderId. The GUID of the VSS provider to use for snapshots on this host. Users typically use the default setting.
public AgentProtectionStorageConfiguration StorageConfiguration { get; set; } Gets or sets the storage configuration.
public string Key { get; set; } Generates a pseudorandom (but not cryptographically secure) key, which can be used as a one-time password to authenticate transfer requests.
public bool IsBaseImage { get; set; } Gets or sets value indicating whether base image will be taken.
public bool IsForced { get; set; } Gets or sets value indicating whether transfer has been forced.
public Guid ProtectionGroupId { get; set; } Gets or sets the ID of the protection group.
public TargetComponentTypes LogTruncationTargets { get; set; } Gets or sets value that indicates for which databases log truncation will be performed (SQL or Exchange).
public bool ForceBaseImage { get } Gets the value indicating whether the base image was forced or not.
public bool IsLogTruncation { get } Gets the value indicating whether the log truncation job is performing or not.

TransferPrescriptParameter (namespace Replay.Common.Contracts.PowerShellExecution)

Inherits its values from the TransferScriptParameterBase parameter.

TransferPostscriptParameter (namespace Replay.Common.Contracts.PowerShellExecution)

The following table presents the available objects for the TransferPostscript parameter. Inherits its value from the TransferScriptParameterBase parameter.

Table 226: Objects for the TransferPostscript parameter
Method Description
public VolumeNameCollection VolumeNames (get; set; ) Gets or sets the collection of volume names for transfer.

VolumeNames is a data structure that contains the following data:

  • GuidName. The Guid associated with the volume, used as the name if a DisplayName is not set.
  • DisplayName. The displayed name of the volume.
public ShadowCopyType ShadowCopyType { get; set; } Gets or sets the type of copying for transfer.ShadowCopyType is an enumeration with values. The available values are:
  • Unknown
  • Copy
  • Full
public AgentProtectionStorageConfigurationCommon StorageConfiguration { get; set; } Gets or sets the storage configuration.
public AgentTransferConfiguration TransferConfiguration { get; set; } Gets or sets the transfer configuration.

AgentTransferConfiguration is an object which will have the following data:

  • MaxConcurrentStreams. The maximum number of concurrent TCP connections the core will establish to the agent for transferring data
  • MaxTransferQueueDepth. The maximum number of block extents which can be queued up for writing
  • MaxConcurrentWrites. The maximum number of block write operations to have outstanding on an epoch at any given time. If additional blocks are received when this many block writes are outstanding, those additional blocks will be ignored until one of the outstanding blocks gets written.
  • MaxSegmentSize. The maximum number of contiguous blocks to transfer in a single request
  • Priority. An object which has the following data:
    • Undefined
    • One
    • Two
    • Three
    • Four
    • Five
    • Six
    • Seven
    • Eight
    • Nine
    • Ten
    • Highest (which is equal to One)
    • Lowest (which is equal to Ten)
    • Default (which is equal to Five)
  • MaxRetries. The maximum number of times a failed transfer should be retried before it is presumed failed
  • UseDefaultMaxRetries. A value indicating that the maximum number of retries is the default value
  • ProviderId. The GUID of the VSS provider to use for snapshots on this host. Administrators typically accept the default.
public AgentTransferConfiguration TransferConfiguration { get; set; } (cont.)
  • ExcludedWriterIds. Collection of VSS writer IDs which should be excluded from this snapshot. The writer ID is keyed by the name of the writer. This name is for documentation purposes only and does not have to exactly match the actual name of the writer.
  • TransferDataServerPort. A value containing the TCP port upon which to accept connections from the core for the actual transfer of data from the agent to the core.
  • SnapshotTimeout. The amount of time to wait for a VSS snapshot operation to complete before giving up and timing out.
  • TransferTimeout. The amount of time to wait for further contact from the core before abandoning the snapshot.
  • NetworkReadTimeout. The timeout for network read operations related to this transfer.
  • NetworkWriteTimeout. The timeout for network write operations related to this transfer.
  • InitialQueueSize. A size of initial queue of requests.
  • MinVolumeFreeSpacePercents. A minimal amount of free space on a volume in percent.
  • MaxChangeLogsSizePercents. A maximum size of driver change logs as part of volume capacity measured in percent.
  • EnableVerification. A value indicating whether diagnostic verification of each block sent to Core should be performed.
public AgentProtectionStorageConfiguration StorageConfiguration { get; set; } Gets or sets the storage configuration

The AgentProtectionStorageConfiguration object contains the following data:

  • RepositoryId. The name of the repository where this agent's recovery points will be stored
  • EncryptionKeyId. The ID of the encryption key for this agent's recovery points. An empty string means no encryption
public string Key { get; set; } The Key method generates a pseudorandom (but not cryptographically secure) key, which can be used as a one-time password to authenticate transfer requests.
public bool ForceBaseImage { get; set; } Gets or sets the value indicating whether the transfer was a forced base image capture.
public bool IsLogTruncation { get; set; } Gets or sets the value indicating whether logging is being truncated.
public uint LatestEpochSeenByCore { get; set; } Gets or sets latest epoch value.

The LatestEpochSeenByCore method is the ordinal number of the most recent snapshot taken by the Core. This is the 'epoch number' assigned by the filter driver to this particular snapshot at the moment it was taken with VSS.

public Guid SnapshotSetId { get; set; } Gets or sets the GUID assigned by VSS to this snapshot.
public VolumeSnapshotInfoDictionary VolumeSnapshots { get; set; } Gets or sets the collection of snapshot info for each volume included in the snapshot.

TransferScriptParameterBase (namespace Replay.Common.Contracts.PowerShellExecution)

The following table presents the available objects for the TransferScriptParameterBase parameter.

Table 227: Objects for the TransferScriptParameterBase parameter
Method Description
public AgentTransferConfiguration TransferConfiguration { get; set; } Gets or sets the transfer configuration.
public AgentProtectionStorageConfigurationCommon StorageConfiguration { get; set; } Gets or sets the storage configuration.

VirtualMachineLocation (namespace Replay.Common.Contracts.Virtualization)

The following table presents the available objects for the VirtualMachineLocation parameter.

Table 228: Objects for the VirtualMachineLocation parameter
Method Description
public string Description { get; set;} Gets or sets a human-readable description of this location.
public string Name { get; set;} Gets or sets the name of the VM.

VolumeImageIdsCollection (namespace Replay.Core.Contracts.RecoveryPoints)

Inherits its values from the parameter, System.Collections.ObjectModel.Collection<string>.

VolumeName (namespace Replay.Common.Contracts.Metadata.Storage)

The following table presents the available objects for the VolumeName parameter.

Table 229: Objects for the VolumeName parameter
Method Description
public string GuidName { get; set;} Gets or sets the ID of the volume.
public string DisplayName { get; set;} Gets or sets the name of the volume.
public string UrlEncode() Gets a URL-encoded version of the name which can be passed cleanly on a URL.

NOTE: A known issue exists in .NET 4.0 WCF (https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=413312), which prevents path escape characters from working correctly in a URI template. Because a volume name contains both '\' and '?', you must replace the special characters '\' and '?' with other special characters.

public string GetMountName() Returns a name for this volume that is valid for mounting volume image to some folder.

VolumeNameCollection (namespace Replay.Common.Contracts.Metadata.Storage)

Inherits its values from the parameter, System.Collections.ObjectModel.Collection<VolumeName>.

The following table presents the available objects for the VolumeNameCollection parameter.

Table 230: Objects for the VolumeNameCollection parameter
Method Description
public override bool Equals(object obj) Determines whether this instance and a specified object, which must also be a VolumeNameCollection object, have the same value. (Overrides Object.Equals(Object).)
public override int GetHashCode() Returns the hash code for this VolumeNameCollection. (Overrides Object.GetHashCode().)

VolumeSnapshotInfo (namesapce Replay.Common.Contracts.Transfer)

The following table presents the available objects for the VolumeSnapshotInfo parameter.

Table 231: Objects for the VolumeSnapshotInfo parameter
Method Description
public Uri BlockHashesUri { get; set;} Gets or sets the URI at which the MD5 hashes of volume blocks can be read.
public Uri BlockDataUri { get; set;} Gets or sets the URI at which the volume data blocks can be read.

VolumeSnapshotInfoDictionary (namespace Replay.Common.Contracts.Transfer)

Inherits its values from the parameter, System.Collections.Generic.Dictionary<VolumeName, VolumeSnapshotInfo>.

Sample PowerShell scripts

The following sample scripts are provided to assist administrative users in executing PowerShell scripts.

PreTransferScript.ps1

The PreTransferScript is run on the protected machine before transferring a snapshot.

Sample PreTransferScript

# receiving parameter from transfer job
param([object]$TransferPrescriptParameter)
# building path to Agent's Common.Contracts.dll and loading this assembly
$regLM = [Microsoft.Win32.Registry]::LocalMachine
$regLM = $regLM.OpenSubKey('SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\AppRecovery Agent 5')
$regVal = $regLM.GetValue('InstallLocation')
$regVal = $regVal + 'Common.Contracts.dll'
[System.Reflection.Assembly]::LoadFrom($regVal)  |  out-null
# Converting input parameter into specific object
$TransferPrescriptParameterObject = $TransferPrescriptParameter -as 
[Replay.Common.Contracts.PowerShellExecution.TransferPrescriptParameter];
# Working with input object. All echo's are logged
if($TransferPrescriptParameterObject -eq $null) {
	echo 'TransferPrescriptParameterObject parameter is null'
}
else {
	echo 'TransferConfiguration:'$TransferPrescriptParameterObject.TransferConfiguration
	echo 'StorageConfiguration:' $TransferPrescriptParameterObject.StorageConfiguration
}
Verwandte Dokumente

The document was helpful.

Bewertung auswählen

I easily found the information I needed.

Bewertung auswählen