Backing up your current cluster

Next, back up your current cluster.

If you're upgrading from 1.0, 1.1.0, or 1.1.1, run the backup script added by the hotfix. If you're upgrading from 1.1.3 or higher, use bdd-admin's backup command. All scripts back up the following data to a single TAR file:
  • Configuration files
  • Studio database
  • Schema and data for Hive tables created in Studio
  • Dgraph databases (index)
  • Sample files in HDFS

You can use this file to restore your current cluster if the upgrade fails.

Before you run the backup script, verify the following:
  • The BDD_STUDIO_JDBC_USERNAME and BDD_STUDIO_JDBC_PASSWORD environment variables are set. If they aren't, the script will prompt you for the username and password of the Studio database at runtime.
  • The database client is installed on the Admin Server. For MySQL databases, this should be MySQL client. For Oracle databases, this should be Oracle Database Client, which must be installed with a type of Administrator. Note that the Instant Client isn't supported.
  • If you have an Oracle database, the ORACLE_HOME environment variable is set to the parent directory of the /bin directory the sqlplus executable is located in. For example, if the sqlplus executable is located in /u01/app/oracle/product/11/2/0/dbhome/bin, set ORACLE_HOME to /u01/app/oracle/product/11/2/0/dbhome.

To back up your current cluster:

  1. On the Admin Server, open a command prompt and go to $BDD_HOME/BDD_manager/bin.
  2. Stop your cluster :
    ./bdd-admin.sh stop [-t <minutes>]
  3. Run the backup script.
    • BDD 1.0:
      ./bdd-backup.sh -v <backup_tar_file>
    • BDD 1.1.0 and 1.1.1:
      ./bdd-backup.sh -o -v <backup_tar_file>
    • BDD 1.2.x:
      ./bdd-admin.sh backup -o -v <backup_tar_file>
    Where <backup_tar_file> is the absolute path to the TAR file your cluster will be backed up to. This file must not exist and its parent directory must be writable.
  4. Enter the username and password for the Studio database, if prompted.

The script backs up your current cluster to the specified TAR file.