In btree/bt_import.c, we explicitly scrub the values in the metadata fields checkpoint_backup_info and checkpoint_lsn in the import repair case:
/* Strip out any incremental backup information, an imported file has not * been part of a backup. Strip out the checkpoint LSN, an imported file * isn't associated with any log files. Assign a unique file ID. */ cfg[1] = a->data; cfg[2] = checkpoint_list; cfg[3] = "checkpoint_backup_info="; cfg[4] = "checkpoint_lsn=";
We do not clear the values in a regular import, which is done in schema/schema_create.
This ticket is to update the import code in the file_create method of schema/schema_create to clear these metadata values prior to inserting the import metadata. The code change should be made in the block below:
if (!import_repair) { WT_ERR(__wt_scr_alloc(session, 0, &val)); WT_ERR(__wt_buf_fmt(session, val, "id=%" PRIu32 ",version=(major=%d,minor=%d)", ++S2C(session)->next_file_id, WT_BTREE_MAJOR_VERSION_MAX, WT_BTREE_MINOR_VERSION_MAX)); for (p = filecfg; *p != NULL; ++p) ; *p = val->data; WT_ERR(__wt_config_collapse(session, filecfg, &fileconf)); }
- is related to
-
WT-7253 Add import functionality to test/format
- Closed