Thread: Clustering
I haven't found any information on clustering with PostgreSQL. One idea we've been tossing around is through PostgreSQL you can create a function that does something when something else happens. Pseudo code: When databse xyz table companyname is updated update the same table and rows in database abc; So each time an update is made, the server performs the function. So every update is essentially 1xN updates (N is the number of servers), but is all done at the server level so should be fast. Now the problem with that solution is if a server db/table gets updated and when it is sending that same update over the net to the offsite cluster, the server crashes. That update technically went through, however the record of it is lost. What is a good clustering technique for PostgreSQL? ~PatHaugen
On Thu, 2005-04-28 at 13:59, Patrick Haugen wrote: > I haven't found any information on clustering with PostgreSQL. > > One idea we've been tossing around is through PostgreSQL you can > create a function that does something when something else happens. > > Pseudo code: > When databse xyz table companyname is updated update the same table > and rows in database abc; > > So each time an update is made, the server performs the function. So > every update is essentially 1xN updates (N is the number of servers), > but is all done at the server level so should be fast. > > Now the problem with that solution is if a server db/table gets > updated and when it is sending that same update over the net to the > offsite cluster, the server crashes. That update technically went > through, however the record of it is lost. > > What is a good clustering technique for PostgreSQL? Something that pretty much does that with the help of a couple of external daemons is the slony project. http://slony.info
On Thu, Apr 28, 2005 at 11:59:59AM -0700, Patrick Haugen wrote: > Pseudo code: > When databse xyz table companyname is updated update the same table > and rows in database abc; ... > What is a good clustering technique for PostgreSQL? Slony-I. Karsten -- GPG key ID E4071346 @ wwwkeys.pgp.net E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346
Karsten Hilbert wrote: > On Thu, Apr 28, 2005 at 11:59:59AM -0700, Patrick Haugen wrote: > > >>Pseudo code: >>When databse xyz table companyname is updated update the same table >>and rows in database abc; > > ... > >>What is a good clustering technique for PostgreSQL? > > > Slony-I. Slony-I isn't clustering. They would have to look at pgCluster or something like that. Sincerely, Joshua D. Drake > > Karsten -- Your PostgreSQL solutions company - Command Prompt, Inc. 1.800.492.2240 PostgreSQL Replication, Consulting, Custom Programming, 24x7 support Managed Services, Shared and Dedication Hosting Co-Authors: plPHP, plPerlNG - http://www.commandprompt.com/
On Thu, 2005-04-28 at 14:54, Joshua D. Drake wrote: > Karsten Hilbert wrote: > > On Thu, Apr 28, 2005 at 11:59:59AM -0700, Patrick Haugen wrote: > > > > > >>Pseudo code: > >>When databse xyz table companyname is updated update the same table > >>and rows in database abc; > > > > ... > > > >>What is a good clustering technique for PostgreSQL? > > > > > > Slony-I. > > Slony-I isn't clustering. They would have to look at pgCluster or > something like that. True. But the description of what the OP wanted to do, slony sounded like what he was after.
> Slony-I isn't clustering. They would have to look at pgCluster or > something like that. Sure but it seemed to fit their description of what they wanted to do. Karsten -- GPG key ID E4071346 @ wwwkeys.pgp.net E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346
From the title alone, "pgCluster" sounded like the perfect choice for PostgreSQL clustering. However on their homepage they provide very little information is a rough english traslation from what it sounds like. Also: http://pgcluster.projects.postgresql.org/feature.html What happens when the load balancer or replicator goes down? Doesn't seem completly stable to me unless I'm missing something. Does anyone have experience with this? slony1 seems to cut out the balancer and replicator and leave the fallover on server crash for you to figure out. I'm liking the sound of this, however again it's tough to find decent readups on the workings of this program. I found this PDF: http://developer.postgresql.org/~wieck/slony1/Slony-I-concept.pdf Provided interesting information, however I'm wondering does anyone know a site that explains it more? Know of any more online writeups in PDF format? Most importantly, anyone have good experience with this? Thanks for the info, ~PatHaugen On 4/28/05, Karsten Hilbert <Karsten.Hilbert@gmx.net> wrote: > > Slony-I isn't clustering. They would have to look at pgCluster or > > something like that. > Sure but it seemed to fit their description of what they > wanted to do. > > Karsten > -- > GPG key ID E4071346 @ wwwkeys.pgp.net > E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346 > > ---------------------------(end of broadcast)--------------------------- > TIP 6: Have you searched our list archives? > > http://archives.postgresql.org >