< Back
Disable-AzureRmRecoveryServicesBackupRPMountScript
Post
NAME Disable-AzureRmRecoveryServicesBackupRPMountScript
SYNOPSIS
Dismounts all the files of the recovery point.
SYNTAX
Disable-AzureRmRecoveryServicesBackupRPMountScript [-RecoveryPoint] <RecoveryPointBase> [-DefaultProfile <IAzureContextContainer>] [-PassThru]
[-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
The Disable-AzureRmRecoveryServicesBackupRPMountScript cmdlet dismounts the files of the recovery point which were mounted earlier using the
Get-AzureRmRecoveryServicesBackupRPMountScript cmdlet.
PARAMETERS
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-PassThru [<SwitchParameter>]
Return the recovery point.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-RecoveryPoint <RecoveryPointBase>
Recovery point object to be restored
Required? true
Position? 0
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
Microsoft.Azure.Commands.RecoveryServices.Backup.Cmdlets.Models.RecoveryPointBase
OUTPUTS
System.Object
NOTES
Example 1: Dismount a recovery point
PS C:\\> $namedContainer = Get-AzureRmRecoveryServicesBackupContainer -ContainerType "AzureVM" -Status "Registered" -FriendlyName "V2VM"
PS C:\\> $backupitem = Get-AzureRmRecoveryServicesBackupItem -Container $namedContainer -WorkloadType "AzureVM"
PS C:\\> $startDate = (Get-Date).AddDays(-7)
PS C:\\> $endDate = Get-Date
PS C:\\> $rp = Get-AzureRmRecoveryServicesBackupRecoveryPoint -Item $backupitem -StartDate $startdate.ToUniversalTime() -EndDate
$enddate.ToUniversalTime()
To mount files of the latest recovery point, obtain the script by
PS C:\\> Get-AzureRmRecoveryServicesBackupRPMountScript -RecoveryPoint $rp[0]
OsType Password Filename
------ -------- --------
Windows e3632984e51f496 V2VM_wus2_8287309959960546283_451516692429_cbd6061f7fc543c489f1974d33659fed07a6e0c2e08740.exe
When the script is run, it will mount the files of the recovery point $rp[0]
After the relevant files are copied, then you remove the files of the recovery point by running the disable cmdlet
PS C:\\> Disable-AzureRmRecoveryServicesBackupRPMountScript -RecoveryPoint $rp[0]
RELATED LINKS
Online Version:
https://docs.microsoft.com/en-us/powers ... ountscript
SYNOPSIS
Dismounts all the files of the recovery point.
SYNTAX
Disable-AzureRmRecoveryServicesBackupRPMountScript [-RecoveryPoint] <RecoveryPointBase> [-DefaultProfile <IAzureContextContainer>] [-PassThru]
[-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
The Disable-AzureRmRecoveryServicesBackupRPMountScript cmdlet dismounts the files of the recovery point which were mounted earlier using the
Get-AzureRmRecoveryServicesBackupRPMountScript cmdlet.
PARAMETERS
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-PassThru [<SwitchParameter>]
Return the recovery point.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-RecoveryPoint <RecoveryPointBase>
Recovery point object to be restored
Required? true
Position? 0
Default value None
Accept pipeline input? True (ByValue)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
Microsoft.Azure.Commands.RecoveryServices.Backup.Cmdlets.Models.RecoveryPointBase
OUTPUTS
System.Object
NOTES
Example 1: Dismount a recovery point
PS C:\\> $namedContainer = Get-AzureRmRecoveryServicesBackupContainer -ContainerType "AzureVM" -Status "Registered" -FriendlyName "V2VM"
PS C:\\> $backupitem = Get-AzureRmRecoveryServicesBackupItem -Container $namedContainer -WorkloadType "AzureVM"
PS C:\\> $startDate = (Get-Date).AddDays(-7)
PS C:\\> $endDate = Get-Date
PS C:\\> $rp = Get-AzureRmRecoveryServicesBackupRecoveryPoint -Item $backupitem -StartDate $startdate.ToUniversalTime() -EndDate
$enddate.ToUniversalTime()
To mount files of the latest recovery point, obtain the script by
PS C:\\> Get-AzureRmRecoveryServicesBackupRPMountScript -RecoveryPoint $rp[0]
OsType Password Filename
------ -------- --------
Windows e3632984e51f496 V2VM_wus2_8287309959960546283_451516692429_cbd6061f7fc543c489f1974d33659fed07a6e0c2e08740.exe
When the script is run, it will mount the files of the recovery point $rp[0]
After the relevant files are copied, then you remove the files of the recovery point by running the disable cmdlet
PS C:\\> Disable-AzureRmRecoveryServicesBackupRPMountScript -RecoveryPoint $rp[0]
RELATED LINKS
Online Version:
https://docs.microsoft.com/en-us/powers ... ountscript