Skip to main content

Restore-ZrClusterCaKey

Restores the cluster CA private key from a passphrase-encrypted backup produced by Backup-ZrClusterCaKey, installing the CA on the connected manager.

Syntax

Restore-ZrClusterCaKey
-InFile <string>
-Passphrase <SecureString>
[-Managers <string[]>] [-Port <int>] [-Token <string>] [-TimeoutSec <int>]
[-WhatIf] [-Confirm]

Description

Restore-ZrClusterCaKey reads a passphrase-encrypted CA-key backup created by Backup-ZrClusterCaKey, decrypts it with the supplied passphrase, and installs the CA on the connected manager, reporting the restored thumbprint. A wrong passphrase or a corrupt backup fails the restore. Requires an active workspace or an explicit -Managers list.

warning

This installs the cluster CA private key — the signing authority for every node certificate — onto the target manager. Run it only when recovering or migrating the cluster CA to a new issuer host, against the manager you intend to make the issuer. Handle the backup file and passphrase as top secrets: never commit them, and remove the backup from the host once the restore succeeds.

Parameters

ParameterTypeRequiredDescription
-InFilestringYesPath to the encrypted CA-key backup file to restore. Position 0.
-PassphraseSecureStringYesPassphrase that was used to encrypt the backup file.
-Managersstring[]NoManagement Service endpoints to target; when omitted the active workspace's managers are used.
-PortintNoManagement Service port for bare-host managers. Default 7801.
-TokenstringNoAdmin bearer token for authenticated control-plane calls.
-TimeoutSecintNoPer-request timeout in seconds. Default 30.

Supports -WhatIf and -Confirm.

Examples

Restore the cluster CA from an encrypted backup using an interactively entered passphrase.

Restore-ZrClusterCaKey -InFile cluster-ca-key.enc -Passphrase (Read-Host -AsSecureString)