pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Koczan <pjkoczan@gmail.com>
To: Vishal Arora <aroravishal22@hotmail.com>
Cc: Anoo Sivadasan Pillai <aspillai@in.rm.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Multiple postgresql serices on same windows machine..
Date: Fri, 8 Feb 2008 16:06:08 -0600
Message-ID: <4544e0330802081406h67ffa843p546a86be1f908e5e@mail.gmail.com> (raw)
In-Reply-To: <BLU110-W15E33BA2BD88A1A450F360A92F0@phx.gbl>
References: <772CDA49C515244FA14E34443F62E56403E6D45B@EX-INDIA1.internal.rmplc.net>
	<BLU110-W15E33BA2BD88A1A450F360A92F0@phx.gbl>

On Feb 7, 2008 11:27 PM, Vishal Arora <aroravishal22@hotmail.com> wrote:
> You can have more than one instance of PostgreSQL server running on the same
> Windows machine as long as you have different DataDir for each of them. you
> can have initdb process indicating different datadir.

And you need each instance (or cluster, as it's usually called in
postgresql lingo) to listen on a different port. Be careful when doing
this because multiple clusters don't play nice with resources like
shared memory.

Anoo, with the usage scenario you suggested, couldn't you just create
some roles in the database cluster, and create new databases? For
example, you could,

- Create the database "app_a_db" and the role "app_a" (with a properly
encrypted password) for Application A. Application A connects to the
server as user "app_a" and does its work in "app_a_db".
- Create the database "app_b_db" and the role "app_b" (with a properly
encrypted password) for Application B. Application A connects to the
server as user "app_b" and does its work in "app_b_db".

app_a doesn't know the password of app_b, and vice-versa, and neither
knows the Windows system passwords for postgres or ServiceAccount.
Since they're working in different databases, they won't interfere
with each other's data. And, you only have to maintain one
cluster/server instead of two.

If it turns out that this doesn't meet your needs, then a separate
cluster is the way to go. I'm just giving you another option. Hope
this helps.

Peter



view thread (3+ messages)

Message-ID: <4544e0330802081406h67ffa843p546a86be1f908e5e@mail.gmail.com>
Permalink:  ../4544e0330802081406h67ffa843p546a86be1f908e5e@mail.gmail.com/
Also on:    postgresql.org/message-id/4544e0330802081406h67ffa843p546a86be1f908e5e@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: pjkoczan@gmail.com, aroravishal22@hotmail.com, aspillai@in.rm.com
  Subject: Re: Multiple postgresql serices on same windows machine..
  In-Reply-To: <4544e0330802081406h67ffa843p546a86be1f908e5e@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox