You are on page 1of 21

ODABR

Oracle Database Appliance – Backup and Restore Utility

Dec 2018
Safe Harbor Statement
The following is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied upon
in making purchasing decisions. The development, release, and timing of any features or
functionality described for Oracle’s products remains at the sole discretion of Oracle.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 3


ODA Backup and Restore - ODABR
It's a best practice to back up the ODA System
Node environment when applying maintenance
to the Oracle Database Appliance.

DBAs typically have elaborate procedures to


backup and recover their databases.

ODA is an appliance and it is important that you


also backup the environment that runs your
database.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 4


ODA Backup and Restore - ODABR
ODA Administrators should create a backup before making significant changes to
their ODA System Node software:

• Application of ODA bundle patches

• Reconfiguration of significant operating parameters

• Deploying non-ODA RPMs or new versions of application software

With a backup ODA administrators can quickly restore a system disk if needed.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 5


ODA Backup and Restore - ODABR
ODABR is a System Backup and Restore Utility that provides the ability to perform an
ODA System Node backup.

• A backup is created using the LVM (logical Volume Manager) snapshot feature of
Linux.
and/or
• A remote backup version of the System Node is created with rsync (A fast, local and
remote file-copying), feature of Linux.

This has been incorporated into a ‘single command’ to simplify the backup and restore
process for ODA.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 6


ODA Backup and Restore - ODABR
The ODA System Node environment includes the following:

• Root file system (/)


• Boot partition (/boot)
• opt file system: OAK/DCS,TFA, OWG, ASR (/opt)
• u01 file system: Grid Infrastructure, RDBMS binaries (/u01)
• Grid Infrastructure OCR file

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 7


ODA System Node Backup/Restore With a Single Command

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 8


ODABR System Node Backup to LVM Snapshot
Example - odabr backup –snap Creates a Snapshot

Using the "-snap" option, odabr will create a LVM snapshot for:
• /dev/VolGroupSys/LogVolU01
• /dev/VolGroupSys/LogVolOpt
• /dev/VolGroupSys/LogVolRoot

The command option "-snap" also creates:


• An image copy of boot partition, storing the "/boot" partition image as
"/opt/odabr/out/hbi/boot.img”

• the Grid Infrastructure OCR backup as


/opt/odabr/out/hbi/ocrbackup_<pid>.bck

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 9


ODABR System Node Backup with Remote Copy
Example – odabr backup –destination ssh://backup@remotehost:/backup
Creates copies at the remote location.

• Creates an LVM snapshot for "/u01", "/opt" and /or "root" (based the user’s selection).

• Uses rsync to perform a physical copy of files to the destination specified.

• This is important when there isn’t enough free space for a Snapshot on the local volume
and to keep the copy remotely.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 10


ODABR System Node Backup with Remote Copy
Example – odabr backup –snap –destination ssh://backup@remotehost:/backup

Creates a local snapshot and copies the files from that point-in-time
snapshot to a remote location that should always be available to the
production system if needed for a restore if restore is not possible from the
local snapshot.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 11


ODABR System Node Infosnap

Example: odabr infosnap


Using "infosnap" option, odabr will show the snapshot existence, the
status and the size %. If a snapshot become inactive it will print a
warning that it is not valid for a restore.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 12


ODABR Suggested Workflow for Backup/Restore Snapshot:
It's best to take a backup on BOTH nodes in an ODA HA before you start the upgrade on any of the
nodes. It's also a good idea to check the disposition of your backup after it's created and before it's used
to restore to be certain it is not marked inactive.

1. odabr backup -snap -destination ssh://backup@remotehost:/backup (Takes a Snapshot and


creates a remote copy of the files)

2. odabr infosnap (Let's you verify the Snapshot is successful)

3. Apply patches or updates, if patches or updates have a problem and after all attempts to repair have
been unsuccessful, you can restore the System Node Snapshot following the remaining steps.

4. odabr infosnap (Make sure the backup has not been marked inactive. If not marked inactive continue
with the restore).

5. odabr restore -snap -boot (Restore from Snapshot, if the Snapshot restore should fail, CONTACT
ORACLE SUPPORT to restore from the remote file copies).

6. If patching or updating is successful you can reboot the node(s)

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 13


ODABR Default Snapshot Sizes
By default ODABR creates LVM snapshots with the following default factory sizes:

• root LVM snapshot 30GB


• opt LVM snapshot 60GB
• u01 LVM snapshot 100GB

If for any reason, your LVM volumes are different in size and or you have less then
190Gb of available free space, you could override these using these command options:

• -rsize
• -osize
• -usize

(Note: You must guarantee enough free space to keep all blocks changes, specify sizes in GBs)

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 14


ODABR System Node Restore from LVM Snapshot

(Example - odabr restore –snap –boot restores the Snapshot)

• Using "-snap", LVM snapshots "remastering" (for "/u01", "/opt" and


"root filesystem") are executed and a reboot is required to make the
changes.

• It may be necessary to restore the /boot partition too. As "/boot" is


not using LVM, it's necessary to restore using '-boot' command
option.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 15


ODABR System Node Restore from Remote Copies

• If the restore from local snapshot fails, since you have created file backups
remotely they can still be used to restore.

• Contact Oracle Support for assistance restoring from remote file copies.

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 16


ODABR Administration
Distributed on My Oracle Support - ODABR a System Backup/Restore Utility (MOS
Doc ID 2466177.1)
• Distributed as an rpm

• Install: rpm –Uvh /tmp/odabr-2.0.1-X.noarch.rpm (installs in: /opt/odabr)

• Uninstall: rpm –e odabr-2.0.1-X/odabr2.0.1X.noarch.rpm

• Logging: Creates a log for all activities:


• Snapshot log: - /opt/odabr/out/log/odabr_<pid>.log
• Rsync Log: /opt/odabr/out/log/rsync_<pid>.log

Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 17


ODABR System Node Backup and Restore
Considerations and Limitations
• ODABR works on ODA BM(Bare Metal) only, but will work on both the OAK and DCS stacks.

• If you need to perform a remote restore, Contact Support for assistance.

• It's important to understand that ODABR is NOT for backing up or restoring the Oracle Database
itself and you can't use ODABR to back up ASM (Automatic Storage Management) content.

• When restoring an LVM snapshot and the previous Grid Infrastructure binaries, it may be
necessary to restore the OCR/Voting file as well. ODABR save the current OCR under
"/opt/odabr/out/hdi/ocrbackup_<pid>.bck". (Documentation explains how to restore the OCR -
(
https://docs.oracle.com/en/database/oracle/oracle-database/12.2/cwadd/managing-oracle-c
luster-registry-and-voting-files.html#GUID-648BB199-AFB9-416A-8438-E0331C255E78
).

• ODABR cannot be used as a tool to perform a Grid Infrastructure downgrade.


Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 18
Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 19
Copyright © 2018, Oracle and/or its affiliates. All rights reserved. | 20

You might also like