From: Craig Ringer <ringerc@ringerc.id.au>
To: d.davolio@mastertraining.it <d.davolio@mastertraining.it>
Cc: pgsql-performance@postgresql.org
Subject: Re: How many Cluster database on a single server
Date: Thu, 20 Oct 2011 11:34:03 +0800
Message-ID: <4E9F96AB.2000002@ringerc.id.au> (raw)
In-Reply-To: <4E9E9C82.4060400@mastertraining.it>
References: <4E9E9C82.4060400@mastertraining.it>
On 10/19/2011 05:46 PM, d.davolio@mastertraining.it wrote:
> My colleagues are asking how many Cluster Databases (initdb) can I
> create and run on a single server. I mean, supposed my server has the
> resources, can I create 100 or even 200 Cluster Databases?
Yep. It won't be fast, but it'll work.
You'll have two performance problems to deal with:
- The memory, CPU and disk I/O overhead of all those extra postmasters,
bgwriters, autovacuum daemons etc running for each cluster; and
- having to split the available shared memory up between each cluster,
so no single cluster gets very much shared memory to use for shared_buffers.
If you keep your shared_buffers low, it should work just fine, but it
won't perform as well as a single PostgreSQL cluster with lots of databases.
In the future I'm hoping someone'll be enthusiastic enough to / need to
add support split WAL logging or partial replication so this sort of
thing isn't necessary. For now it does seem to be the best way to handle
cases where different databases need different replication.
--
Craig Ringer
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-performance@postgresql.org
Cc: ringerc@ringerc.id.au, d.davolio@mastertraining.it
Subject: Re: How many Cluster database on a single server
In-Reply-To: <4E9F96AB.2000002@ringerc.id.au>
* 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