Return-Path: owner-postman Received: from LOCALHOST (LOCALHOST [127.0.0.1]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with SMTP id PAA14170 for postgres-redist; Thu, 9 Jun 1994 15:43:53 -0700 Resent-From: POSTGRES mailing list Resent-Message-Id: <199406092243.PAA14170@nobozo.CS.Berkeley.EDU> Sender: owner-postman@postgres.Berkeley.EDU X-Return-Path: owner-postman Received: from faerie.CS.Berkeley.EDU (faerie.CS.Berkeley.EDU [128.32.149.14]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with ESMTP id PAA14160 for ; Thu, 9 Jun 1994 15:43:52 -0700 Received: from LOCALHOST (LOCALHOST [127.0.0.1]) by faerie.CS.Berkeley.EDU (8.6.4/8.1B) with SMTP id PAA18870; Thu, 9 Jun 1994 15:43:49 -0700 Message-Id: <199406092243.PAA18870@faerie.CS.Berkeley.EDU> X-Authentication-Warning: faerie.CS.Berkeley.EDU: Host LOCALHOST didn't use HELO protocol From: aoki@CS.Berkeley.EDU (Paul M. Aoki) To: perera@pollux.cs.uga.edu (Niranjan Perera) Cc: postgres@postgres.Berkeley.EDU Reply-To: aoki@CS.Berkeley.EDU (Paul M. Aoki) Subject: Re: How does POSTGRES handle crash recovery ? Date: Thu, 09 Jun 94 15:43:49 -0700 X-Sender: aoki@postgres.Berkeley.EDU Resent-To: postgres-redist@postgres.Berkeley.EDU X-Mts: smtp Resent-Date: Thu, 09 Jun 94 15:43:53 -0700 Resent-XMts: smtp > I would like to know how POSTGRES handles "crash recovery". somebody else writes in private email: Consult the $POSTGRESDIR/doc/papers directory for a paper on the novel implementation of crash recovery in a PG database. Basicly, there is no WAL (Write Ahead Log) and no undo or redo recovery. Each write is a distinct tuple in the relation, and the oid keeps track of updates. Selects can then be 'time restricted' because the entire history of the relation is stored in the relation. Several relations; pg_log, pg_time etc, maintain logs of open transactions. If the machine crashes, you simply start it up again. Any uncommited transactions are not noted in the log and hence simply aren't there, so far as PG is concerned. This gives you, effectively, instant re-start. This is gone into in mush more detail in the docs noted above . . . one plus of the postgres storage manager is the "instant crash recovery." one minus is that it does not address media failure (e.g., bad sectors). the stock answer to the media failure problem is to throw hardware at it (e.g., use raid -- mirrored files, ecc, whatever). frequent (offline) backups are recommended in the new documentation. ("backup frequently" is always safe DBA advice, i suppose..) -- Paul M. Aoki | CS Div., Dept. of EECS, UCB | aoki@CS.Berkeley.EDU | Berkeley, CA 94720 | ...!uunet!ucbvax!aoki ============================================================================== To add/remove yourself to/from the POSTGRES mailing list: send mail with the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU" If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and a human will deal with it. DO NOT post to the "postgres" mailing list. ==============================================================================