> I just put a CHECKPOINT command on both sides of my COPY
> statement, and it seemed to go quite a bit faster and not
Hmm, why would COPY be faster just after CHECKPOINT.
I assume this was caused by some fortuity (like preparing
new log file at checkpoint time - server does it even if
wal_files = 0 but current log file is 75% full).
> give me any problems. Does that make sense?
Of couse. Also remember
> > Third - unfortunately (from my POV), we requires two checkpoint in
> > log files now, so we do not remove files with records between last
> > two checkpoints.
Some additional CPKT-s may be required.
BUT, I forgot about fourth point - server logs *entire* data pages on first
after last CPKT page modification. It doesn't affect COPY-ed tables (when
first
row goes to new page just this row will be logged) but may affect indices
and UPDATE/DELETE ops.
So, one should be very careful when using CPKT-s.
Vadim