Backing up the management subsystem

Use apicup to create a manual backup of the management subsystem

Before you begin

You must have configured backups for the subystem. See Configuring backup settings during initial installation of the management subsystem

About this task

Use this task to create an on-demand, or manual, backup of the management system.

To set up scheduled backups, see the schedule option in Configuring backup settings during initial installation of the management subsystem.

Procedure

  1. Ensure that there are no Management subsystem backups in Running state before creating a new Management backup.
  2. Ensure your system is healthy:
    apicup subsys health-check [subsystem_name]

    When successful, the command returns silently with an exit code of 0.

  3. Make sure that the management cluster status is Running and the READY condition displays the same value before and after the "/".

    SSH into the appliance and run kubectl:

    kubectl get mgmt
    NAME   READY   STATUS    VERSION      RECONCILED VERSION   AGE
    mgmt   16/16   Running   10.0.2.0   10.0.2.0        19h
    Note: Be sure READY status is 16/16. If you have just configured or reconfigured the backup settings, there is a period of time when the postgres pods are taken offline and brought back up with the new configuration. During this time, the kubectl get mgmt command will show 11/11 instead of 16/16. If you start a backup before the Management cluster is on 16/16, the backup attempt might stall indefinitely.
  4. Create a backup:
    apicup subsys backup [subsystem_name] [flags]
    Decide which of the two types of manual backups you want to do:
    • full: backs up the entire Management subsystem database.
      apicup subsys backup management --type full
    • incr: backs up any data that has not been backed up since the last full or incr backup.
      apicup subsys backup management  --type incr

    To view additional flags, use -h:

    ./apicup subsys backup management -h
    Backup management subsystem 
    Usage:
      backup SUBSYS [flags]Flags:
          --debug                   Enable debug logging
      -h, --help                    help for backup
          --type string             Type of backup to take ['incr' (backup data starting from last backup), 'full' (complete backup)] (default "full")
          --wait                    Wait for the operation to complete or fail.
          --wait-timeout duration   Command timeout in seconds. (default 40s)