pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Basic Postgresql Performance Question
5+ messages / 4 participants
[nested] [flat]

* Basic Postgresql Performance Question
@ 2004-06-16 19:15  Bill <bill@math.uchicago.edu>
  0 siblings, 2 replies; 5+ messages in thread

From: Bill @ 2004-06-16 19:15 UTC (permalink / raw)
  To: pgsql-performance

Hi,
I currently have a mysql server running with a database of around 800
gb.  The problem is that the server is old (500 MHz Pentium III with 512
MB RAM) and I want to change this to a new server and convert the
existing database to Postgresql on Debian (I assume that Postgresql
offers better performance for complex read only queries on large
databases), though I was wondering if

1.  It is possible to have some sort of load-balancing through buying
many computers without replication, i.e have one server which has the
databases and then other servers which has no database but just exists
to balance the memory and processor load? (I have heard this is possible
with C-JDBC)It is difficult to have enough space to replicate a 600 gb
database across all computers)

2.  It is advantageous to buy AMD 64 rather than the Pentium IV?

Any thoughts?
Thanks. 




^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Basic Postgresql Performance Question
@ 2004-06-16 19:35  Stephen Frost <sfrost@snowman.net>
  parent: Bill <bill@math.uchicago.edu>
  1 sibling, 1 reply; 5+ messages in thread

From: Stephen Frost @ 2004-06-16 19:35 UTC (permalink / raw)
  To: Bill <bill@math.uchicago.edu>; +Cc: pgsql-performance

* Bill (bill@math.uchicago.edu) wrote:
> I currently have a mysql server running with a database of around 800
> gb.  The problem is that the server is old (500 MHz Pentium III with 512
> MB RAM) and I want to change this to a new server and convert the
> existing database to Postgresql on Debian (I assume that Postgresql
> offers better performance for complex read only queries on large
> databases), though I was wondering if

Excellent plan.  If you're looking at using Debian stable I'd encourage
you to consider using the PostgreSQL back-port of 7.4.2 to Debian stable
on backports.org.

> 1.  It is possible to have some sort of load-balancing through buying
> many computers without replication, i.e have one server which has the
> databases and then other servers which has no database but just exists
> to balance the memory and processor load? (I have heard this is possible
> with C-JDBC)It is difficult to have enough space to replicate a 600 gb
> database across all computers)

I don't think so...  There's something called OpenMosix which does this
on independent processes but not for threaded programs (since it doesn't
make sense to split them across different nodes if they're accessing the
same memory- every memory access would have to be checked) like the
PostgreSQL server.

> 2.  It is advantageous to buy AMD 64 rather than the Pentium IV?

Personally, I certainly think so.  More registers, more memory possible
inside one application, other stuff...

	Stephen

Attachments:

  signature.asc (application/pgp-signature, 188B) download

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Basic Postgresql Performance Question
@ 2004-06-16 20:08  Kevin Barnard <kbarnard@speedfc.com>
  parent: Stephen Frost <sfrost@snowman.net>
  0 siblings, 0 replies; 5+ messages in thread

From: Kevin Barnard @ 2004-06-16 20:08 UTC (permalink / raw)
  To: Stephen Frost <sfrost@snowman.net>; +Cc: Bill <bill@math.uchicago.edu>; pgsql-performance


Stephen Frost wrote:

>>1.  It is possible to have some sort of load-balancing through buying
>>many computers without replication, i.e have one server which has the
>>databases and then other servers which has no database but just exists
>>to balance the memory and processor load? (I have heard this is possible
>>with C-JDBC)It is difficult to have enough space to replicate a 600 gb
>>database across all computers)
>>    
>>
>
>I don't think so...  There's something called OpenMosix which does this
>on independent processes but not for threaded programs (since it doesn't
>make sense to split them across different nodes if they're accessing the
>same memory- every memory access would have to be checked) like the
>PostgreSQL server.
>
>  
>
Look at www.linuxlabs.com they have a clustering system.  Not exactly 
the same thing but close to what I think you are looking for.

-- 
Kevin Barnard

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Basic Postgresql Performance Question
@ 2004-06-16 20:18  Scott Marlowe <smarlowe@qwest.net>
  parent: Bill <bill@math.uchicago.edu>
  1 sibling, 1 reply; 5+ messages in thread

From: Scott Marlowe @ 2004-06-16 20:18 UTC (permalink / raw)
  To: Bill <bill@math.uchicago.edu>; +Cc: pgsql-performance

On Wed, 2004-06-16 at 13:15, Bill wrote:
> Hi,
> I currently have a mysql server running with a database of around 800
> gb.  The problem is that the server is old (500 MHz Pentium III with 512
> MB RAM) and I want to change this to a new server and convert the
> existing database to Postgresql on Debian (I assume that Postgresql
> offers better performance for complex read only queries on large
> databases),

Usually, but there are always queries that run faster or slower on a
given database due to differences in architecture and design.  For
instance PostgreSQL tends to be slow when doing max/min aggs, but faster
when doing things involving complex joins and unions.

>  though I was wondering if
> 
> 1.  It is possible to have some sort of load-balancing through buying
> many computers without replication, i.e have one server which has the
> databases and then other servers which has no database but just exists
> to balance the memory and processor load? (I have heard this is possible
> with C-JDBC)It is difficult to have enough space to replicate a 600 gb
> database across all computers)

That depends.  Most databases are first I/O bound, then memory bound,
then CPU bound, in that order.  With an 800Gb database your main "cost"
is gonna be moving data off of the platters and into memory, then having
the memory to hold the working sets, then the CPU to mush it together.

Now, if you're reading only tiny portions at a time, but doing lots of
strange work on them, say weather forcasting, then you might be CPU
bound.  But without knowing what your usage patterns are like, we don't
know whether or not running on multiple boxes would help.  There are
replication systems, but there's no such thing as a free lunch.

> 2.  It is advantageous to buy AMD 64 rather than the Pentium IV?

Yes and no.  If having more than 2 gigs of ram is important, 64 bit
architecures run faster than 32 bit, where having over 2 gigs usually
results in a slow down due to the memory switching they use.




^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Basic Postgresql Performance Question
@ 2004-06-16 20:49  Stephen Frost <sfrost@snowman.net>
  parent: Scott Marlowe <smarlowe@qwest.net>
  0 siblings, 0 replies; 5+ messages in thread

From: Stephen Frost @ 2004-06-16 20:49 UTC (permalink / raw)
  To: Scott Marlowe <smarlowe@qwest.net>; +Cc: Bill <bill@math.uchicago.edu>; pgsql-performance

* Scott Marlowe (smarlowe@qwest.net) wrote:
> On Wed, 2004-06-16 at 13:15, Bill wrote:
> > 2.  It is advantageous to buy AMD 64 rather than the Pentium IV?
> 
> Yes and no.  If having more than 2 gigs of ram is important, 64 bit
> architecures run faster than 32 bit, where having over 2 gigs usually
> results in a slow down due to the memory switching they use.

This is truer on more traditional 64bit platforms than on amd64 which
has more differences than just the ability to handle 64bit size things.
amd64 also gives you access to more registers than were on the
register-starved i386 platforms which increases the speed for most
applications where it usually wouldn't when recompiled for 64bit.

	Stephen

Attachments:

  signature.asc (application/pgp-signature, 188B) download

^ permalink  raw  reply  [nested|flat] 5+ messages in thread


end of thread, other threads:[~2004-06-16 20:49 UTC | newest]

Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2004-06-16 19:15 Basic Postgresql Performance Question Bill <bill@math.uchicago.edu>
2004-06-16 19:35 ` Stephen Frost <sfrost@snowman.net>
2004-06-16 20:08   ` Kevin Barnard <kbarnard@speedfc.com>
2004-06-16 20:18 ` Scott Marlowe <smarlowe@qwest.net>
2004-06-16 20:49   ` Stephen Frost <sfrost@snowman.net>

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