From: | "Hartwig Jens" <Jens(dot)Hartwig(at)t-systems(dot)de> |
---|---|
To: | "Phuong Ma" <pma(at)commandprompt(dot)com>, "Postgres-general" <pgsql-general(at)postgresql(dot)org> |
Subject: | RE: WAL article |
Date: | 2001-06-08 05:34:48 |
Message-ID: | 819FEEAC94E6DC459F1FDC83C0C1611F1BCC9C@mail2000.b3.dsh.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hello Phuong,
you asked for a review of your article about WAL. The article sounds
good. I have some few annotations (to everybody: please correct me, if I
am wrong):
1. The data is not written to permanent data (to the database) when a
commit OR a checkpoint occurs but only if a checkpoint occurs. When a
commit is done the data are flushed from the memory into the log-files.
Uncommitted changes need not to be recovered after a crash.
2. Precisely, a user cannot continue from the point before the crash but
he can continue from the last COMMITTED point before the crash.
3. You do not create an exact number of segments by using WAL_FILES but
you create a number (max. 64) of files in advance. Unused logfiles will
be removed after setting a savepoint and a number of new segments will
be created.
Best regards, Jens Hartwig
-----------------------------------------------------
T-Systems
Project Manager
debis Systemhaus GEI GmbH
Address: Eichhornstrae 3, 10785 Berlin
Postal Address: 10785 Berlin
Phone: (004930) 25 54-32 82
Fax: (004930) 25 54-31 87
Mobile: (0170) 167 26 48
E-Mail: jens(dot)hartwig(at)t-systems(dot)de
Internet: http://www.t-systems.de
> -----Previous Message -----
> From: Phuong Ma [mailto:pma(at)commandprompt(dot)com]
> Sent: Freitag, 8. Juni 2001 01:07
> To: Postgres-general
> Subject: [GENERAL] WAL article
>
>
> Hello everyon,
>
> I'm writing a section about Write Ahead Logging. I would appreciate
> it if you can read this and give me some feedback. Such as: Is it
> correct? Clear? Precise?
>
> If there is anything wrong, please email me.
>
> Thank you ALL.
> --------------------------------------
> Write Ahead Logging (WAL)
>
> This Postgres feature enables database administrators to increase
> database performance. It does this through writing log records of all
> modifications before the commit is performed. When the
> commit occurs or
> when a checkpoint is reached, the log files are then written to
> permanent data. Therefore, the file modified does not change until it
> is logged.
>
> The advantage of using Write Ahead Logging is when a crash occurs
> before the commit is executed, the log will still exist and
> the changes
> are not lost. The modifications can then be retrieved from the log
> files. A user can continue to work from the point they were at before
> the crash occurred.
>
> WAL consists of the following main elements:
>
> Segments
> These memory buffer segments are files which are
> 16MB in size.
> When the usage level reaches 75% of the segment, then a new segment is
> then created. To create an exact number of segments, modify the
> WAL_FILES parameters.
>
> log files
> These files contain an ordered list of REDO/UNDO
> actions. They
> also contain the new and old data. These log files are written
> consecutively, one after the other. This causes the WAL to access the
> log in sequential order, making the WAL process even faster.
>
> checkpoints
> These are points in a sequence of transactions. When these
> points are reached, the log files created before these points are
> ensured to have been committed.
>
>
> WAL enables the system to avoid the process of writing to
> disk on every
> transaction commit. There is a decrease in the number of disk writes
> happening, causing the disk access to speed up.
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>
From | Date | Subject | |
---|---|---|---|
Next Message | Willis, Ian (Ento, Canberra) | 2001-06-08 06:18:45 | RE: PostgreSQL 7.1 and ORACLE 8.x |
Previous Message | Prasanth Kumar | 2001-06-08 05:34:21 | Re: Maximum Limit of the database for no. of records. |