Re: Isolated databases or instances - Mailing list pgsql-admin

From Scott Marlowe
Subject Re: Isolated databases or instances
Date
Msg-id 1171667421.3565.119.camel@state.g2switchworks.com
Whole thread Raw
In response to Re: Isolated databases or instances  ("Henry, Nigel, CYFD" <nigel.henry@state.nm.us>)
List pgsql-admin
On Fri, 2007-02-16 at 16:30, Henry, Nigel, CYFD wrote:
> More information:
>
> As stated, this is going to be a SLES 9.3 environment -- 64-bit.
> VMWare, for now, is out of the question because we currently only have
> IBM HS20 blades which are unable to host the 64-bit environment in
> VMWare.  So we're running the OS on bare metal.  As I mentioned in my
> original post, we are trying to use our blades wisely by creating the
> three separate, isolated environments across the blades.  Much like
> this: #
> separate install instances of the HTTP server (3 -- DEV/Test/UAT) 1st
> blade;
> separate install instances of the application server
> (3 -- DEV/Test/UAT) 2nd blade -- the HTTP server will be installed
> from the application build rather than as a separate install; and
> three PostgreSQL database instances (3 -- DEV/Test/UAT) on the last
> blade.
> This is the only way we can create three environments since even
> though we have three blades, the blade housing databases belongs to
> the DBA group.  The application being developed is in Java and is not
> a transaction-intensive application.

So, would you need to do things like upgrade postgresql one environment
at a time, or would you be ok with all three environments sharing one
pgsql instance with three separate databases in it?

One instance is much easier to setup and maintain, and it is often the
case in a dev/uat/test environment that only one instance is ever
working hard, so the performance will likely be better on a single
instance than on multiples.

You could also have pg_hba.conf set to only let certain users connect
from certain ips to certain databases, limiting the possibility of one
layer (uat/test/dev) hitting the wrong database.

If you need the isolation provided by three separate instances, then you
can easily do it by creating a couple extra users, and putting the dbs
in their home directories running on different ports.  That way, the
pg82dev user and the pg82uat user and the pg82test user all run on, say,
ports 5433, 5434, and 5435, and they can't accidentally mess each other
up, because they're completely different.  You don't need a special
install or anything.  Just keep in mind you'll need to allocate enough
shared memory to make all three instances happy.

pgsql-admin by date:

Previous
From: "Chad Wagner"
Date:
Subject: Re: WAL files backup
Next
From: pedro noticioso
Date:
Subject: Re: WAL files backup