用 BACKUP 映像 RESTORE INTO 異名目標庫時,DB2 默認會將源庫配置文件覆蓋回目標庫,導致精心調優的參數 (如 UTIL_HEAP_SZ) 失效。
| Seed 比對結果 | DB2 行為 |
|---|---|
| 不一致 (默認跨庫情況) | 覆蓋目標庫配置文件 ← 源映像配置 |
| 一致 | **保留目標庫配置文件**,不覆蓋 |
環境: 源庫 SAMPLE → 目標庫 TEST,保護參數 UTIL_HEAP_SZ。
db2ckbkp -H <backup_image_file> # 輸出中 "Database Seed -- 423AD856"
db2 update db cfg for test using util_heap_sz 10000 (驗證生效)。db2 restore db sample into test → 警告覆蓋,確認 y。UTIL_HEAP_SZ 變回源庫值 5000。423AD856)。db2 update db cfg for test using util_heap_sz 15000。db2 restore db sample into test (同源映像)。UTIL_HEAP_SZ **保持 15000**,未被覆蓋!