You can list the available backup files on the sftp server.
Procedure
-
Run the following command to connect to the management subsystem as the API Connect
administrator.
ssh ip_address -l apicadm
- Select Yes to continue connecting, and once
connected, get necessary credentials:
- Authenticate by using the sftp key:
kubectl exec $POD -n <namespace> -- bash -c "/sftp/backup.sh -L -H $HOST -u $USERNAME -k /sshd/sftp-key -d $DIRECTORY"
- Alternatively, authenticate using username/password:
kubectl exec $POD -n <namespace> -- bash -c "/sftp/backup.sh -L -H $HOST -u $USERNAME -p $PASSWORD -d $DIRECTORY"
- Alternatively, if running within the interactive shell of the Backup and Restore
Pod:
/sftp/backup.sh -L -H $HOST -u $USERNAME -k /sshd/sftp-key -d $DIRECTORY
/sftp/backup.sh -L -H $HOST -u $USERNAME -p $PASSWORD -d $DIRECTORY
Example
$ /sftp/backup.sh -L -H $HOST -u $USERNAME -k /sshd/sftp-key -d $DIRECTORY
drwxr-xr-x 2 root root 90 Aug 26 09:21 .
drwxrwxrwt 10 root root 198 Aug 26 09:45 ..
-rw-r--r-- 1 root root 13092333 Aug 26 08:56 20200826-154646F.tgz
-rw-r--r-- 1 root root 18703758 Aug 26 09:10 20200826-160010F.tgz
-rw-r--r-- 1 root root 24318561 Aug 26 09:21 20200826-161301F.tgz
These files correspond to the IDs of mgmtb
backup instances.