X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 54CBC563D9 for ; Thu, 12 May 2005 05:48:46 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 96903-08 for ; Thu, 12 May 2005 08:48:39 +0000 (GMT) Received: from mail49.messagelabs.com (mail49.messagelabs.com [193.109.255.19]) by svr1.postgresql.org (Postfix) with SMTP id E1C41563D7 for ; Thu, 12 May 2005 05:48:37 -0300 (ADT) X-VirusChecked: Checked X-Env-Sender: alexs@advfn.com X-Msg-Ref: server-8.tower-49.messagelabs.com!1115887716!16482921!1 X-StarScan-Version: 5.4.11; banners=-,-,- X-Originating-IP: [212.161.99.149] Received: (qmail 1409 invoked from network); 12 May 2005 08:48:36 -0000 Received: from mail.advfn.com (212.161.99.149) by server-8.tower-49.messagelabs.com with SMTP; 12 May 2005 08:48:36 -0000 Received: from [213.86.19.101] (helo=[192.168.0.185]) by mail.advfn.com with esmtp (Exim 4.22) id 1DW9My-0006i1-1n; Thu, 12 May 2005 09:48:36 +0100 In-Reply-To: References: <5F94B6EB-3925-4CD3-A67F-4310890B438A@advfn.com> <1115798277.29223.233869472@webmail.messagingengine.com> <200505111013.52067.josh@agliodbs.com> Mime-Version: 1.0 (Apple Message framework v728) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Cc: josh@agliodbs.com, "David Roussel" , pgsql-performance@postgresql.org Content-Transfer-Encoding: 7bit From: Alex Stapleton Subject: Re: Partitioning / Clustering Date: Wed, 11 May 2005 23:56:54 +0100 To: PFC X-Mailer: Apple Mail (2.728) X-Virus-Scanned: by amavisd-new at hub.org X-Archive-Number: 200505/230 X-Sequence-Number: 12394 On 11 May 2005, at 23:35, PFC wrote: > > > >> However, memcached (and for us, pg_memcached) is an excellent way >> to improve >> horizontal scalability by taking disposable data (like session >> information) >> out of the database and putting it in protected RAM. >> > > So, what is the advantage of such a system versus, say, a > "sticky sessions" system where each session is assigned to ONE > application server (not PHP then) which keeps it in RAM as native > objects instead of serializing and deserializing it on each request ? > I'd say the sticky sessions should perform a lot better, and if > one machine dies, only the sessions on this one are lost. > But of course you can't do it with PHP as you need an app > server which can manage sessions. Potentially the savings are huge, > though. Theres no reason it couldn't be done with PHP to be fair as long as you could ensure that the client was always routed back to the same machines. Which has it's own set of issues entirely. I am not entirely sure that memcached actually does serialize data when it's comitted into memcached either, although I could be wrong, I have not looked at the source. Certainly if you can ensure that a client always goes back to the same machine you can simplify the whole thing hugely. It's generally not that easy though, you need a proxy server of some description capable of understanding the HTTP traffic and maintaining a central session lookup table to redirect with. Which isn't really solving the problem so much as moving it somewhere else. Instead of needing huge memcached pools, you need hardcore loadbalancers. Load Balancers tend to cost $$$$$ in comparison. Distributed sticky sessions are a rather nice idea, I would like to hear a way of implementing them cheaply (and on PHP) as well. I may have to give that some thought in fact. Oh yeah, and load balancers software often sucks in annoying (if not always important) ways. > On Google, their distributed system spans a huge number of PCs > and it has redundancy, ie. individual PC failure is a normal thing > and is a part of the system, it is handled gracefully. I read a > paper on this matter, it's pretty impressive. The google filesystem > has nothing to do with databases though, it's more a massive data > store / streaming storage. > Since when did Massive Data stores have nothing to do with DBs? Isn't Oracle Cluster entirely based on forming an enormous scalable disk array to store your DB on?