Crash recovery

Started by Soroosh Sardariabout 12 years ago2 messages
#1Soroosh Sardari
soroosh.sardari@gmail.com

Hi

When PG crashes or the computer turned down unexpectedly, next time
postmaster
starts up, it does the crash recovery, actually redo xlog records, vacuum,
etc.

What module is responsible for crash recovery?

Regards,
Soroosh Sardari

#2Heikki Linnakangas
hlinnakangas@vmware.com
In reply to: Soroosh Sardari (#1)
Re: Crash recovery

On 05.11.2013 13:21, Soroosh Sardari wrote:

When PG crashes or the computer turned down unexpectedly, next time
postmaster
starts up, it does the crash recovery, actually redo xlog records, vacuum,
etc.

What module is responsible for crash recovery?

See src/backend/access/transam/xlog.c. The code to read the WAL is
there. It calls redo-routines in other modules, see e.g heap_redo for
replaying heap records, btree_redo for B-tree index records and so forth.

- Heikki

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers