Control File - Mailing list pgsql-hackers

From Bruno Almeida do Lago
Subject Control File
Date
Msg-id 4433f9e1.06ff948a.2b91.0be0@mx.gmail.com
Whole thread Raw
Responses Re: Control File
List pgsql-hackers
Quick (real) story to illustrate situation:

Some time ago we used to have a server with 2 disk arrays attached to it.
They were /mnt/array1 and /mnt/array2. PostgreSQL (8.0) had tablespaces on
both.

In one cold & dark night, one SCSI controller from array2 stopped, and
manufacturer was called to replace it. The "system administrator" (monkey)
from the night called the DBA (sleeping...monkey? -- ups... that's me), and
asked for him to stop the database so he could umount /mnt/array2.

Sleeping DBA took his coffee, and stopped the database. Monkey umounted
array2 and changed the SCSI controller which came alive again!

Monkey calls & wake DBA (again): - Everything went fine, SCSI controller
"successfully" replaced. Could you please wake up again and start the
database?

DBA takes another coffee and finally started the database which... just came
up! Few minutes latter lot off errors being displayed. What is that???
/mnt/array2 (50% of datafiles and tablespaces were there) was still umounted
and even so PostgreSQL came up. -- PostgreSQL stopped, /mnt/array2 mounted,
started and... - happy end!


After that night, I started to ask myself if PostgreSQL should not have a
control file to check if expected datafiles are where they should be and
JUST warn about missing ones?

If yes, I apply for developing the patch.


C ya,
Teolupus





pgsql-hackers by date:

Previous
From: "Peter Brant"
Date:
Subject: Re: Stats collection on Windows
Next
From: "Nathan Buchanan"
Date:
Subject: Re: Summer of Code Preparation