Appearance
Backup and Restore Clients
The backup and restore clients are part of the ybtools
package. Some of the parameters and options are the same as those used by other tools (such as the logging and connectivity options). See Client Tools and Drivers.
These tools connect to the database via JDBC as Java client applications. After you have downloaded and installed the ybtools
, you can run the ybbackup
, ybrestore
, and ybbackupctl
commands:
ybbackup
: for running full, cumulative, and incremental backupsybrestore
: for running full and incremental restoresybbackupctl
: for listing, copying, deleting, and purging backups
Note: You must run ybbackup
and ybrestore
commands as a database superuser. Regular users cannot run these commands. The ybbackupctl
command does not require a database connection, so superuser access is not required.
Getting Online Help
Use one of the following options to return online help text for ybbackup
, ybrestore
, or ybbackupctl
:
-?
--help
--help-advanced
The following example returns help for the ybbackup
command:
myuser@myybd:~/usr/bin$ ./ybbackup -?
Yellowbrick Backup and Restore version 6.1.3-20221102160444
Backup one database and associated metadata on a Yellowbrick appliance to the specified bundle
Common Options:
-?, --help
Display this help message
--version
Shows the version number
...
Setting Up a Database Connection
To run backup and restore operations, you have to start a database session on the server where the target database resides. This session requires connection information that you can provide either as ybbackup
or ybrestore
options on the command line or as current values for environment variables.
Note: These connection parameters are not required for ybbackupctl
commands. These commands do not require a database connection.
Command-Line Options | Environment Variable | Description | Example |
---|---|---|---|
-h or --host | YBHOST | Destination server host name. Default: localhost | -h test.ybsystem.io export YBHOST=test.ybsystem.io |
-p or --port | YBPORT | Destination server port number. Default: 5432 | --port 5433 export YBPORT=5433 |
-U or --username | YBUSER | Database login username. No default. | -U bobr export YBUSER=bobr Note: You must run ybbackup and ybrestore commands as a database superuser. Regular users cannot run these commands. You can run the ybbackupctl command as any database user because this command does not require a connection to a database. |
-W or --password | YBPASSWORD | Interactive prompt for the database user's password. No default. | --password export YBPASSWORD=******** |