Archiving Online - TARA/ABU

Teradata Archive/Recovery Utility Reference

Product
TARA/ABU
Release Number
15.00
Language
English (United States)
Last Update
2018-09-25
dita:id
B035-2412
lifecycle
previous
Product Category
Teradata Tools and Utilities

Archiving Online

Online archiving allows concurrent updates to tables during the archive process. Any updates during the archive are logged so that they can be rolled back to a consistent point during a restore.

There are different ways to start and stop online archiving. Use the ONLINE keyword in the ARCHIVE statement or the LOGGING ONLINE ARCHIVE ON and LOGGING ONLINE ARCHIVE OFF statements.

The ONLINE keyword in the ARCHIVE statement specifies that the objects listed in the statement are to be archived online. Then, Teradata Archive/Recovery Utility automatically enables logging before archiving the listed objects and automatically disables logging after the listed objects are archived. This method can be used for all-AMP archives and non-cluster multi-stream archives.

The LOGGING ONLINE ARCHIVE ON statement explicitly starts online logging for one or more objects in the system. Subsequent ARCHIVE statements on these objects (without using the ONLINE keyword) will perform an online archive, allowing concurrent updates. Use this method for cluster archives and Dictionary archives and when one wishes to separate groups of tables into smaller sets of consistency points to reduce impact on write transactions.

The LOGGING ONLINE ARCHIVE OFF statement stops online logging on the specified objects. This statement must be submitted for all objects after the online archive is complete if the LOGGING ONLINE ARCHIVE ON statement was used, or if an online archive job fails. If LOGGING ONLINE ARCHIVE OFF is not submitted, logging will continue on the objects indefinitely.

When the Online table is restored or copied, the changes recorded in the Online log are used to roll back those changes in the table to the consistency point that was established when online logging was started on that table. The consistency point for an individual table may be different from the consistency point of other tables in the Online Archive job, based on when online logging was enabled on that table.

If used on the ARCHIVE statement, the NOSYNC option can be specified, but only if the ONLINE option is also specified. The NOSYNC option affects how Online Logging is enabled on the involved tables.

The primary purpose of NOSYNC is to provide an option that has minimal impact on transactions writing to the database. When trying to establish a common consistency point across a large number of tables to enable logging on all of those tables at the same time, it is best to pause the write transactions on those tables. This pause in activity on those tables allows the DBS to establish a common consistency point. This pause is not needed for the other phases of Online Archive. If this pause is not practical, then NOSYNC is an alternative way to enable logging on a large number of tables without having to establish a single common consistency point.

NOSYNC may require some additional CPU and elapsed time since individual Online Logging requests may have to be sent to the Teradata Database and some blocked lock time may have to be endured. If a sufficiently large number of tables are involved, it may be desirable to break up the archive into multiple smaller jobs.

If any table is still enabled for Online Logging either after the archive is finished or due to a graceful abnormal termination of Teradata ARC, a warning message appears indicating that one or more tables are still enabled for online logging. A series of these messages may appear after archiving an object, at the end of an Archive statement, and when Teradata ARC is terminated with a FATAL error (severity level 12 or higher).

If one of these messages appears, determine which table(s) is still online logging (either from the job output or by using the query in “Determining Whether Online Archive Logging is in Use” on page 49). Then determine if those tables should continue to log or not. If not, then use the LOGGING ONLINE ARCHIVE OFF statement to turn off online logging for those tables that should not be logging.

When starting ONLINE ARCHIVE on one or more objects, the following conditions are handled differently based on the target database version.