You can back up Yugabyte platform using file server agent.
Prerequisite
-
Add Yugabyte anywhere and high availability (HA) nodes as clients in the Commvault command center.
-
Install the Commvault file system package on the yugabyte anywhere node and the required HA nodes.
-
The user used during the Commvault file system package installation must have permissions to execute the pre-scan and post recovery script files on both the source and destination clients.
-
Save the pre-scan backup, post-backup cleanup and restore commands in separate files. For example, /yb-bkp-script, /bkp-cleanup-script and /yb-restore-script.
-
Example of the Backup and Cleanup Script File
Suppose /yba-backup is the output path where you want to store the backup.tar file.
-
For Replicated Installations
$ cat yb-bkp-script ./yb_platform_backup.sh create --output /yba-backup -
For Installations Using yba-installer
$ cat yb-bkp-script sudo yba-ctl createBackup /yba-backup -
Post-backup Cleanup File
$ cat bkp-cleanup-script rm -rf /yba-backup/*
-
-
Example of The Restore Script File along with Cleanup If Necessary
Suppose /yba-restore/backup_24-07-30-01-08.tgz is the absolute path of the input tar file.
-
For Replicated Installations
$ cat yb-restore-script ./yb_platform_backup.sh restore --input /yba-restore/backup_24-07-30-01-08.tar rm -rf /yba-restore/* -
For Installations Using yba-installer
$ cat yb-restore-script sudo yba-ctl restoreBackup /yba-restore/backup_24-07-30-01-08.tgz rm -rf /yba-restore/*
-
-
Procedure
-
From the navigation pane, go to Protect > File servers.
The file server Overview page appears.
-
Go to the File servers tab.
-
From the file servers list, click the Yugabyte file server.
The Yugabyte file server Overview page appears.
-
Go to Subclients tab, and then click Add subclient.
The Add Subclient page appears.
-
Under the General section, in the Subclient name box, enter the name of the subclient, and then click NEXT.
The Plan page appears.
-
Select a backup plan, and then click NEXT.
The Backup Content page appears.
-
In the Backup content section, from the Add list, select Browse.
The Add content dialog box appears.
-
Select the folder which can be used as an output path to store the Yugabyte backup .tar.gz file, and then click Save.
-
To access the data with saved user credentials, move the Impersonate user toggle key to right, and then enter the user credentials.
-
Click Submit.
-
The subclient is added to the Yugabyte file server.
-
From the Subclients tab, click the added subclient.
The subclient Overview page appears.
-
In the Pre-process and post-process commands tile, click Advanced Settings.
The Edit pre-process and post-process commands dialog box appears.
-
Under the Scan process settings section, enter the following details:
- In the Pre-scan process box, enter the file name containing the Yugabyte backup script (for example, yb-bkp-script ). You can also select the file using the folder icon.
-
In the Backup process settings section, enter the following details:
- In the Post-backup process box, enter the post-backup process command file or select a post-backup process command file using the folder icon.
Note
If you want to remove the .tar files restored to the backup location, do the following:
- Either add a command to empty the folder after each backup in the post-backup script or remove the files manually.
-
Move the Run post-backup process for all attempts toggle key to right if you want to run a post-backup process for all the backup attempts.
-
To access the data with saved user credentials, move the Impersonate user toggle key to right, and then enter the user credentials.
-
Click Save.
-
From the Subclients tab, in the row for the Yugabyte subclient, click the action button
, and then click Backup.The Backup dialog box appears.
-
You can select one of the following backups:
-
Full
-
Incremental
-
Synthetic full
-
-
Click Submit.
Result
The Yugabyte backup script is executed as a pre-scan process, and then the generated output .tgz file is backed up.