QUIESCE utility in DB2 for z/OS

A quiesce point is a bookmark on the Db2 log where a set of table spaces is consistent: no half-finished unit of recovery is sitting in those objects. The QUIESCE utility writes that bookmark (log RBA or LRSN) into SYSIBM.SYSCOPY so you can later RECOVER to it. This page covers table spaces, partitions, table space sets, WRITE YES/NO, catalog rules, and why “QUIESCE DATABASE” in conversation usually means a LIST of spaces—not a DATABASE keyword.

Db2 utilities
Progress0 of 0 lessons

What QUIESCE records

Phases: UTILINIT, QUIESCE (determine the point and update the catalog), UTILTERM. The quiesce point is the current log RBA or, in data sharing, LRSN. SYSCOPY gets a row with ICTYPE='Q' for each table space and for COPY YES indexes on those spaces. Four catalog/directory spaces log the information instead of SYSCOPY: SYSTSCPY, DBD01, SYSUTILX, SYSDBDXA.

You do not have to QUIESCE in order to do a point-in-time recover—RECOVER can apply consistency (committed data only) without a Q row. Recovering to a quiesce point can be faster because Db2 does not need to back out in-flight work. Use QUIESCE when a related set must share one point (RI parents and children, base plus LOBs).

Objects you can quiesce

QUIESCE control statement options
OptionMeaning
TABLESPACE db.tsQuiesce this table space. Database defaults to DSNDB04.
PART nPhysical partition 1–4096. Same space with PART m and PART n quiesces each once.
TABLESPACESETQuiesce the RI set plus LOB and XML auxiliaries of the named space.
LIST listdefOne LIST of table spaces (optional partition ranges). Not with TABLESPACE/TABLESPACESET.
CLONEClone data only; LISTDEF CLONED YES is not sufficient.
WRITE YES | NOYES writes changed pages for the spaces and their indexes to disk.

Table space and partition

QUIESCE TABLESPACE db.ts is the basic form. PART integer limits the job to one physical partition. Naming the same space twice with different PART values quiesces each partition once. Memory in the batch address space and DBM1 limits how many objects you can list. Duplicating a space without PART still quiesces it once and warns with DSNU533I (RC 4).

Table space set

TABLESPACESET means: this space plus everything IBM treats as one recoverability set for QUIESCE:

  • Table spaces related by referential constraints
  • The base table space with all of its LOB table spaces
  • The base table space with all of its XML table spaces

On a system-period temporal table or its history table space, QUIESCE includes both sides of the versioning relationship and their LOB/XML auxiliaries. The TABLESPACE keyword is optional on TABLESPACESET.

LIST and CLONE

One LIST per QUIESCE statement; the LISTDEF must contain only table spaces (partition ranges allowed). Do not mix LIST with TABLESPACE or TABLESPACESET. Related index spaces count as list items for OPTIONS ITEMERROR. CLONE processes clone data; CLONED YES on LISTDEF is not enough.

There is no QUIESCE DATABASE verb

To quiesce “the database,” build a LISTDEF of its table spaces (or list them) and run one QUIESCE so they share a common point. QUIESCE is not STOP DATABASE: applications are drained only long enough to reach a consistent log point, then continue.

sql
1
2
3
4
5
6
7
8
9
10
11
QUIESCE TABLESPACE PAYDB.EMPTS WRITE YES; QUIESCE TABLESPACE PAYDB.EMPTS PART 3 WRITE YES; QUIESCE TABLESPACESET TABLESPACE PAYDB.ORDTS WRITE YES; QUIESCE LIST PAYCRIT WRITE YES;

WRITE YES and WRITE NO

WRITE YES (the usual choice) writes changed pages for the table spaces and their indexes from the buffer pool to disk so DASD matches the quiesce RBA/LRSN. WRITE NO still records the SYSCOPY Q row (for ordinary spaces) but skips that forced write. Use WRITE YES before an outside copy of VSAM data sets or a tool that reads DASD directly. Reasons a write can fail include drain timeouts and objects in pending status—DISPLAY DATABASE and the utility messages tell you.

Catalog, directory, and pending objects

  • You can QUIESCE DSNDB01.SYSUTILX alone—not in a list with other spaces
  • For catalog/directory PIT recovery, quiesce the other catalog/directory spaces, then quiesce DSNDB06.SYSTSCPY separately afterward
  • Prefer recover-to-current for catalog/directory when you can
  • Authorization: IMAGCOPY, DBADM/DBCTRL/DBMAINT, System DBADM, SYSCTRL, SYSADM. Installation SYSOPR: DSNDB01 and DSNDB06 only

QUIESCE on a space already in a restrictive pending state may fail or skip the write. Reset or recover first. After QUIESCE, REPORT RECOVERY shows the new Q row. MODIFY RECOVERY later deletes old Q rows with the rest of the history.

Do not confuse QUIESCE the utility with -STOP DB2 MODE(QUIESCE) or -STOP DDF MODE(QUIESCE). Those operator commands drain the subsystem or DDF. The utility only bookmarks a consistency point for named spaces.

Explain It Like I'm Five

Imagine several related storybooks (parent table, child table, photo-LOB box) that must always match. QUIESCE is everyone pausing at the same sentence in the diary (the log) while the librarian writes that sentence number on a sticky note (SYSCOPY ICTYPE Q). Later, if you rewind the stories, you rewind to that sticky note and all three books agree. WRITE YES also photocopies the pages onto the shelf so a camera pointed at the shelf sees the same sentence. WRITE NO only writes the sticky note. You cannot QUIESCE “the whole library building” with one magic word—you list the books that belong together, which is what TABLESPACESET and LISTDEF are for.

Exercises

  1. Write QUIESCE for PAYDB.ORDTS including its RI children and LOB spaces, forcing pages to disk.
  2. You need a common point for every table space in database PAYDB. Sketch a LISTDEF plus QUIESCE (no DATABASE keyword).
  3. Why might recovering to a Q row be faster than recovering to an arbitrary LRSN even though both can be consistent?
  4. Plan a catalog/directory quiesce if you truly need PIT recoverability, including SYSTSCPY order.
  5. Contrast QUIESCE WRITE YES with -STOP DATABASE and with SET LOG SUSPEND.

Quiz

Test Your Knowledge

1. What is a quiesce point?

  • A STOP DB2 MODE(FORCE)
  • A log RBA or LRSN at which the named objects are transactionally consistent, recorded in SYSIBM.SYSCOPY as ICTYPE Q
  • A CHECK-pending flag
  • An IRLM deadlock

2. Does the QUIESCE utility have a DATABASE keyword?

  • Yes, QUIESCE DATABASE(db) is required
  • No—you quiesce TABLESPACE, PART, TABLESPACESET, or a LISTDEF list. To cover a whole database, list its spaces or use LISTDEF
  • Only for DSNDB07
  • Only with WRITE NO

3. What does TABLESPACESET include?

  • Only the one space you named
  • Referentially related table spaces, plus the base space’s LOB and XML table spaces (and versioning/history auxiliaries when you quiesce a temporal pair)
  • Only indexes
  • Only work files

4. WRITE(YES) versus WRITE(NO)?

  • WRITE NO deletes SYSCOPY
  • WRITE YES (typical default) externalizes changed pages for the table spaces and their indexes from the buffer pool to disk; WRITE NO records the quiesce RBA without that forced write
  • WRITE NO is required for catalog
  • They are identical

5. Can you QUIESCE an index space by name?

  • Yes, QUIESCE INDEXSPACE is the usual form
  • No—quiesce the table space; Db2 also inserts SYSCOPY Q rows for COPY YES indexes on that space
  • Only NPSIs
  • Only with PART