Hi,
Are you talking about checking for files in the pg_commit_ts directory of the old cluster?
The possibility of copying the catalog is checked here:
+ /*
+ * Copy old commit_timestamp data to new, if available.
+ */
+ is_copy_commit_ts =
+ (old_cluster.controldata.chkpnt_oldstCommitTsxid > 0 &&
+ old_cluster.controldata.chkpnt_newstCommitTsxid > 0 &&
+ user_opts.do_copy_pg_commit_ts);
+
+ if (is_copy_commit_ts)
+ {
+ copy_subdir_files("pg_commit_ts", "pg_commit_ts");
+ oldest_xid = old_cluster.controldata.chkpnt_oldstCommitTsxid;
+ newest_xid = old_cluster.controldata.chkpnt_newstCommitTsxid;
+ }
+ else
+ oldest_xid = newest_xid = old_cluster.controldata.chkpnt_nxtxid;
+
Do I need to check something else additionally in the old cluster before copying the pg_commit_ts directory?
----------------
Кому: 'ls7777' (ls7777@yandex.ru);
Копия: pgsql-hackers@postgresql.org, orlovmg@gmail.com, amit.kapila16@gmail.com, Masahiko Sawada (sawada.mshk@gmail.com);
Тема: Patch for migration of the pg_commit_ts directory;
01.06.2026, 06:25, "Hayato Kuroda (Fujitsu)" <kuroda.hayato@fujitsu.com>:
Dear Sergey,
During copying, the copy_subdir_files function cleans up the target
directory with the remove_new_subdir(new_subdir, true) function.
Correct, the function can discard existing directory. But my point was that how
do we ENSURE it's OK to remove.
Best regards,
Hayato Kuroda
FUJITSU LIMITED