pgsql/src/backend/access/transam (xact.c xlog.c)
Date: Sunday, November 5, 2000 @ 17:50:19
Author: vadim
Update of /home/projects/pgsql/cvsroot/pgsql/src/backend/access/transam
from hub.org:/home/projects/pgsql/tmp/cvs-serv21922/src/backend/access/transam
Modified Files:
xact.c xlog.c
----------------------------- Log Message -----------------------------
New CHECKPOINT command.
Auto removing of offline log files and creating new file
at checkpoint time.
vadim@postgresql.org writes:
New CHECKPOINT command.
Auto removing of offline log files and creating new file
at checkpoint time.
Is this the same as a SAVEPOINT?
--
Peter Eisentraut peter_e@gmx.net http://yi.org/peter-e/
New CHECKPOINT command.
Auto removing of offline log files and creating new file
at checkpoint time.Is this the same as a SAVEPOINT?
No. Checkpoints are to speedup after crash recovery and
to remove/archive log files. With WAL server doesn't write
any datafiles on commit, only commit record goes to log
(and log fsync-ed). Dirty buffers remains in memory long
time - only when some transaction is going to use unpinned
dirty buffer its content will be written (but not fsync-ed)
to system buffer cache. So, at any time some changes made by
transactions would be saved on disk, others would be in system
cache and some of them in server buffer pool. In the event of
crash recoverer should know what changes are on disk, ie -
from what position in log it should try to start redo
operation ((re-)applying changes). Obviously, it's not
good to start from first log record -:) For this purposes
checkpoints are used. At checkpoint time (each ~ 3-5 minutes)
*all* dirty buffers is forced to disk and checkpoint record
is written to log, so recoverer will know that up to the
last record in log made before checkpoint started all changes
are on disk and redo is not required for previous records.
Vadim
Import Notes
Resolved by subject fallback
New CHECKPOINT command.
Auto removing of offline log files and creating new file
at checkpoint time.
Can you tell me how to use CHECKPOINT please?
Is this the same as a SAVEPOINT?
No. Checkpoints are to speedup after crash recovery and
to remove/archive log files. With WAL server doesn't write
any datafiles on commit, only commit record goes to log
(and log fsync-ed). Dirty buffers remains in memory long
Is log fsynced even I turn of -F?
--
Tatsuo Ishii