Db2 High Availability Disaster Recovery (HADR) replicated operations
- Data definition language (DDL)
- Data manipulation language (DML)
- Buffer pool operations
- Table space operations
- Online reorganization
- Offline reorganization
- Metadata for stored procedures and user defined functions (but not the associated object or
library files). Java stored procedures that are saved as
.jarfiles are one exception; more information is provided below.
During an online table reorganization, all operations are logged in detail, which can generate large numbers of log records. This process can cause the standby database to fall behind. Multiple concurrent online reorganizations on tables residing in the same table space have a greater impact on the standby falling behind compared to tables residing in different table spaces. Avoid running multiple concurrent online table reorganizations in parallel.
While offline reorganizations are not logged as extensively as online reorganizations, operations are typically logged per hundreds or thousands of affected rows. This means that the standby database could fall behind because it waits for each log record and then replays many updates at once. If the offline reorganization is non-clustered, a single log record is generated after the entire reorganization operation. This mode has the greatest impact on the ability of the standby database to keep up with the primary database. The standby database will perform the entire reorganization after it receives the log record from the primary database.
HADR does not replicate stored procedures or UDF object and library files, therefore you must create the files on identical paths on both the primary and standby databases. If the standby database cannot find the referenced object or library file, the stored procedure or UDF invocation will fail on the standby database.
.jar files. After failover, applications
receive a SQL4304N message when accessing the stored procedure on the new HADR primary database. To
avoid this message, you must run sqlj.refresh_classes() or
sqlj.recoverjar() before the stored procedure can be used. Note that this
complication does not apply to Java stored procedures which are saved as .java
files.