diff --git a/tools/backup_db.sh b/tools/backup_db.sh new file mode 100755 index 000000000..aa82f1dba --- /dev/null +++ b/tools/backup_db.sh @@ -0,0 +1,15 @@ +#!/usr/bin/env bash +# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. +# +# + +if [ "$#" -lt 2 ]; then + echo "usage: ${BASH_SOURCE[0]} " + exit 1 +fi + +db_dir="$1" +backup_dir="$2" + +echo "== Backing up DB $db_dir to $backup_dir" +./ldb backup --db="$db_dir" --backup_dir="$backup_dir" diff --git a/tools/check_format_compatible.sh b/tools/check_format_compatible.sh index c7d86027e..1d4076995 100755 --- a/tools/check_format_compatible.sh +++ b/tools/check_format_compatible.sh @@ -1,25 +1,83 @@ #!/usr/bin/env bash # Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. # -# A shell script to load some pre generated data file to a DB using ldb tool -# ./ldb needs to be avaible to be executed. +# A shell script to build and run different versions of ldb to check for +# expected forward and backward compatibility with "current" version. The +# working copy must have no uncommitted changes. +# +# Usage: