8.15 Restoring a Backup After a Password Change

If you have changed the password for Oracle VM Manager or its related components Oracle WebLogic Server and Oracle MySQL database, and you need to restore the Oracle VM Manager from a backup that was made prior to the password change, the passwords will be out of sync. As a result of this password mismatch, Oracle VM Manager cannot connect to its database and cannot be started, so you must first make sure that the passwords are identical.

Note

The steps below are not specific to the case where a password changed occurred after the backup. They apply to any restore operation.

As of Release 2.3.1, which includes Oracle VM Manager 3.4.2, the database data directory cleanup is built into the restore process, so that step can be skipped.

Resolving Password Mismatches when Restoring Oracle VM Manager from a Backup

  1. Create a manual backup of the Oracle VM Manager MySQL database to prevent inadvertent data loss. On the command line of the active management node, run the following command:

    • Release 2.2.x and older:

      # /u01/app/oracle/ovm-manager-3/bin/createBackup.sh -n ManualBackup1
    • Release 2.3.1 and newer:

      # /u01/app/oracle/ovm-manager-3/ovm_tools/bin/BackupDatabase -w
      INFO:  Backup started to:
               /u01/app/oracle/mysql/dbbackup/ManualBackup-20170324_102412
  2. In the Oracle PCA Dashboard, change the Oracle MySQL database password back to what it was at the time of the backup.

  3. On the command line of the active management node, as root user, stop the Oracle VM Manager and MySQL services, and then delete the MySQL data.

    # service ovmm stop
    # service ovmm_mysql stop
    # cd /u01/app/oracle/mysql/data
    # rm -rf appfw ibdata ib_logfile* mysql mysqld.err ovs performance_schema
  4. As oracle user, restore the database from the selected backup.

    • Release 2.2.x and older:

      # su oracle
      $ bash /u01/app/oracle/ovm-manager-3/ovm_shell/tools/RestoreDatabase.sh BackupToBeRestored
      INFO: Expanding the backup image...
      INFO: Applying logs to the backup snapshot...
      INFO: Restoring the backup...
      INFO: Success - Done!
      INFO: Log of operations performed is available at: 
            /u01/app/oracle/mysql/dbbackup/BackupToBeRestored/Restore.log
    • Release 2.3.1 and newer:

      # su oracle
      $ bash /u01/app/oracle/ovm-manager-3/ovm_tools/bin/RestoreDatabase.sh BackupToBeRestored
      INFO: Expanding the backup image...
      INFO: Applying logs to the backup snapshot...
      INFO: Restoring the backup...
      INFO: Success - Done!
      INFO: Log of operations performed is available at: 
            /u01/app/oracle/mysql/dbbackup/BackupToBeRestored/Restore.log
  5. As root user, start the MySQL and Oracle VM Manager services.

    $ su root
    # service ovmm_mysql start
    # service ovmm start

    After both services have restarted successfully, the restore operation is complete.