Thread: Postgresql and OS cluster

Postgresql and OS cluster

From
Nilabhra Banerjee
Date:
Hi friends,

I am loading Potsgresql in shared hard disks. The Disk
cluster is shared by two nodes. The nodes can access
the disks asynchronously, i.e, the node coming up
first gets disk. I have loaded the postgresql in local
disk of one node and issued initdb command to put the
datapath in shared disk and then created database.
Right now I am installing postgresql in local disk of
node 2, that must point to the same database in shared
disk. Now do I need to run initdb again... or running
postmaster directly (when node 2 is up and node 1 is
down) can make the database up?

Regards
Nil





___________________________________________________________ALL-NEW Yahoo! Messenger - all new features - even more fun!
http://uk.messenger.yahoo.com 

Re: Postgresql and OS cluster

From
Greg Stark
Date:
Nilabhra Banerjee <nil_ban@yahoo.co.uk> writes:

> Now do I need to run initdb again... or running postmaster directly (when
> node 2 is up and node 1 is down) can make the database up?

No, a postgres database consists entirely of the files in the data directory.
If the database process is set up properly to read those files either with -D
on startup or the PGDATA environment variable then you're done.

But you do have to be very careful to never have both nodes up at the same
time. If they are I think your database will quickly be corrupted. And both
nodes have to be the same architecture and compiled the same way.

--
greg