Work in progress
You can use wal-g as a tool for encrypting, compressing FoundationDB backups and push/fetch them to/from storage.
To compile and build the binary for FoundationDB:
Optional:
USE_LIBSODIUM
environment variable.USE_LZO
environment variable.go get github.com/wal-g/wal-g
cd $GOPATH/src/github.com/wal-g/wal-g
make install
make deps
make fdb_build
Users can also install WAL-G by using make install
. Specifying the GOBIN environment variable before installing allows the user to specify the installation location. On default, make install
puts the compiled binary in go/bin
.
export GOBIN=/usr/local/bin
cd $GOPATH/src/github.com/wal-g/wal-g
make install
make deps
make fdb_install
backup-fetch
Command for sending backup from storage to stream in order to restore it in the database.
wal-g backup-fetch example_backup
Variable WALG_STREAM_RESTORE_COMMAND is required for use backup-fetch
(eg. TMP_DIR=$(mktemp -d) && chmod 777 $TMP_DIR && tar -xf - -C $TMP_DIR && BACKUP_DIR=$(find $TMP_DIR -mindepth 1 -print -quit) && fdbrestore start -r file://$BACKUP_DIR -w --dest_cluster_file "/etc/foundationdb/fdb.cluster" 1>&2
)
WAL-G can also fetch the latest backup using:
wal-g backup-fetch LATEST
backup-push
Command for compressing, encrypting and sending backup from stream to storage.
wal-g backup-push
Variable WALG_STREAM_CREATE_COMMAND is required for use backup-push
(eg. TMP_DIR=$(mktemp -d) && chmod 777 $TMP_DIR && fdbbackup start -d file://$TMP_DIR -w 1>&2 && tar -c -C $TMP_DIR .
)
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。