pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ron Mayer <rm_pg@cheapcomplexdevices.com>
To: Chuming Chen <chen@musc.edu>
Subject: Re: run httpd and postgresql on different machines ?
Date: Tue, 18 Jan 2005 16:49:18 -0800
Message-ID: <41EDAE8E.8030604@cheapcomplexdevices.com> (raw)
In-Reply-To: <41ED10E2.6030502@musc.edu>
References: <41ED10E2.6030502@musc.edu>

Chuming Chen wrote:
> 
> I want to set up a web site using apache httpd, php and postgresql. From 
> the performance point of view, which  architecture is better? 1)  Run 
> httpd and postgresql on the same machine; 2) Run postgresql on seperate 
> machine. My concern is that the machine I am going to run httpd has 
> limitted storage. I am expecting the increasing of postgresql database 
> once I set it ip.

I had good luck with 4 very cheap (small, used, 1CPU, IDE disk)
machines running httpd/php/MONO-ASP.NET, and 1 more expensived
machine (with some internal failover capabilities - dual power
supplies, with a RAID array, with a support contract) running
postgresql.

The reasoning was one of cost/performance with the ability to
have likely-to-fail components fail with no downtime.

The cheapest way to scale the front-end machines with failover
capabilities was to use sub-$1000 slightly obsolete PCs.
The cheapest way I knew to provide limited scalability
and failover (at least for disk) for a database was a raid array.

With some of the newer replication features or pgpool, it might
be easier to scale "out" instead of "up"; but I have no experience
making that determination.

How about the rest of you guys....

If CPU demands in my database get to the point of needing 5-CPUs
with a read-mostly (90%) system, am I better off with
   1 lots of replication between small servers
  or
   2 scaling up a big server.

(the reason I'm CPU bound instead of disk bound is that many
of my queries are spatial operations with PostGIS like unions
and buffers of polygons).



view thread (4+ messages)

Message-ID: <41EDAE8E.8030604@cheapcomplexdevices.com>
Permalink:  ../41EDAE8E.8030604@cheapcomplexdevices.com/
Also on:    postgresql.org/message-id/41EDAE8E.8030604@cheapcomplexdevices.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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: rm_pg@cheapcomplexdevices.com, chen@musc.edu
  Subject: Re: run httpd and postgresql on different machines ?
  In-Reply-To: <41EDAE8E.8030604@cheapcomplexdevices.com>
  References: <41ED10E2.6030502@musc.edu> <41EDAE8E.8030604@cheapcomplexdevices.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