@@ -228,7 +228,7 @@ get_control_data(ClusterInfo *cluster, bool live_check)
228
228
pg_fatal ("%d: controldata retrieval problem\n" , __LINE__ );
229
229
230
230
p ++ ; /* removing ':' char */
231
- cluster -> controldata . chkpnt_tli = str2uint (p );
231
+ tli = str2uint (p );
232
232
got_tli = true;
233
233
}
234
234
else if ((p = strstr (bufin , "Latest checkpoint's NextXID:" )) != NULL )
@@ -478,11 +478,11 @@ get_control_data(ClusterInfo *cluster, bool live_check)
478
478
* Before 9.3, pg_resetxlog reported the xlogid and segno of the first log
479
479
* file after reset as separate lines. Starting with 9.3, it reports the
480
480
* WAL file name. If the old cluster is older than 9.3, we construct the
481
- * WAL file name from the xlogid and segno.
481
+ * WAL file name from the tli, xlogid, and segno.
482
482
*/
483
483
if (GET_MAJOR_VERSION (cluster -> major_version ) <= 902 )
484
484
{
485
- if (got_log_id && got_log_seg )
485
+ if (got_tli && got_log_id && got_log_seg )
486
486
{
487
487
snprintf (cluster -> controldata .nextxlogfile , 25 , "%08X%08X%08X" ,
488
488
tli , logid , segno );
@@ -496,7 +496,6 @@ get_control_data(ClusterInfo *cluster, bool live_check)
496
496
(!got_oldestmulti &&
497
497
cluster -> controldata .cat_ver >= MULTIXACT_FORMATCHANGE_CAT_VER ) ||
498
498
(!live_check && !got_nextxlogfile ) ||
499
- !got_tli ||
500
499
!got_align || !got_blocksz || !got_largesz || !got_walsz ||
501
500
!got_walseg || !got_ident || !got_index || !got_toast ||
502
501
!got_date_is_int || !got_float8_pass_by_value || !got_data_checksum_version )
@@ -524,9 +523,6 @@ get_control_data(ClusterInfo *cluster, bool live_check)
524
523
if (!live_check && !got_nextxlogfile )
525
524
pg_log (PG_REPORT , " first WAL segment after reset\n" );
526
525
527
- if (!got_tli )
528
- pg_log (PG_REPORT , " latest checkpoint timeline ID\n" );
529
-
530
526
if (!got_align )
531
527
pg_log (PG_REPORT , " maximum alignment\n" );
532
528
0 commit comments