DSA Restore Locking Strategy | Teradata DSA - DSA Restore Locking Strategy - BAR - Data Stream Architecture

Teradata® DSA User Guide

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
BAR
Data Stream Architecture
Release Number
17.20
Published
November 2022
Language
English (United States)
Last Update
2023-11-30
dita:mapPath
bis1632417576364.ditamap
dita:ditavalPath
vwp1576617377804.ditaval
dita:id
cyv1467242268519
Product Category
Software
Teradata Tools and Utilities

At the start of processing a restore job, DSA gets a Host Utility (HUT) Exclusive lock on every object in the job plan. Since the object definition and the data are being written, DSA needs an exclusive lock on these objects so there are no conflicts writing to the system. If the job plan includes a database, then DSA puts an Exclusive HUT lock on the whole database. If the job plan includes an object, then DSA puts an Exclusive HUT lock on the object.

In addition, the restore puts write locks on several DBC tables while the object definitions are being restored. These locks are held during the dictionary phase. Tables that are locked include: TEXTTBL, IDCOL, DEPENDENCY, JAR_JAR_USAGE, ROUTINE_JAR_USAGE, ERRORTBLS, JARS, STATSTBL, QUERYSTATSTBL, REFERENCEDTBLS, REFERENCINGTBLS, UNRESOLVEDREFERENCES, CONSTRAINTNAMES, TRIGGERSTBL, OBJECTUSAGE, UIF_INFO, SERVERTBLOPINFO, DBCASSOCIATION, TVM, INDEXES, TVFIELDS, UDFINFO, and TABLECONSTRAINTS. Access locks are also placed on DBASE and DATASETSCHEMAINFO. These are table level locks.

A restarted job may place a table level HUT lock even if the original job definition is a database level restore.

For example, Job1 copies DB1 and DB2 at the database level. DB1 and DB2 have table1, table2, and table3 respectively, and the job aborts after DB1.table1 is complete. DB1 is partially complete and no object in DB2 is complete. In this case, the restart job places a table level lock on DB1.table2 and DB1.table3 and places a database level lock on DB2.

The HUT Exclusive lock is released as soon as the object is completely restored.
  • Objects without a table header that are restored at the object level have the lock released at the end of the dictionary phase.
  • Tables that are restored at the object level have the lock released as soon as the object is completely restored.
  • Database level locks have the lock released as soon as all the objects in the database have been completely restored.
  • [Analytics Database 16.20 and later / Teradata Database 16.0 and later] If the empty table option is selected during backup, the locks on the empty tables are released at the end of dictionary phase if they were restored at the table level.