Restores the CA database and private key information.
The Restore-CARoleService cmdlet restores the certification authority (CA) database and private key information.
-DatabaseOnly
Indicates that the cmdlet restores only the certification authority database.
Required? true
Position? named
Default value
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Force <SwitchParameter>
Forces the command to run without asking for user confirmation.
Required? false
Position? named
Default value
Accept pipeline input? True (ByValue, ByPropertyName)
Accept wildcard characters? false
-KeyOnly <SwitchParameter>
Indicates that the cmdlet restores only the certification authority private key and certificate.
Required? true
Position? named
Default value
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Password <SecureString>
Specifies a password, as a secure string, to access the private key and certificate information. To obtain a secure string, use the ConvertTo-SecureString cmdlet. For more information, type Get-Help ConvertTo-SecureString.
Required? false
Position? named
Default value
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-Path <String>
Specifies the directory from which the cmdlet restores the CA database and private key. The cmdlet restores the database from the subdirectory named Database in the path that you specified when you backed up the CA database. The cmdlet restores the private key from the .p12 file that you backed up in the Database subdirectory in the path that you specify.
Required? true
Position? 2
Default value
Accept pipeline input? True (ByValue, ByPropertyName)
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
Restore-CARoleService [-Path] [-Force ] -DatabaseOnly [-Confirm ] [-WhatIf ] []
Restore-CARoleService [-Path] <String> [-Force ] [-Password <SecureString>] -KeyOnly [-Confirm ] [-WhatIf ] [<CommonParameters>]
Restore-CARoleService [-Path] <String> [-Force ] [-Password <SecureString>] [-Confirm ] [-WhatIf ] [<CommonParameters>]
Example 1: Restore the CA private key and certificate
PS C:> Restore-CARoleService -Path “C:\CABackup”
This command restores the CA private key and certificate from the specified path.
Example 2: Restore the CA database only
PS C:>Restore-CARoleService –Path “C:\CABackup” –DatabaseOnly
This command restores the CA database from the specified path. The command does not restore the CA private key information.
PS C:>Restore-CARoleService –Path “C:\CABackup” -KeyOnly
This command restores the CA private key information to the specified path. The command does not restore the CA database.
Get-Command Restore-CARoleService
Backup-CARoleService