Unix Technical Forum

db performance/design question

This is a discussion on db performance/design question within the Pgsql Performance forums, part of the PostgreSQL category; --> I'm designing a system that will be doing over a million inserts/deletes on a single table every hour. Rather ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > Pgsql Performance

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-19-2008, 11:33 AM
Matt Chambers
 
Posts: n/a
Default db performance/design question


I'm designing a system that will be doing over a million inserts/deletes
on a single table every hour. Rather than using a single table, it is
possible for me to partition the data into multiple tables if I wanted
to, which would be nice because I can just truncate them when I don't
need them. I could even use table spaces to split the IO load over
multiple filers. The application does not require all this data be in
the same table. The data is fairly temporary, it might last 5 seconds,
it might last 2 days, but it will all be deleted eventually and
different data will be created.

Considering a single table would grow to 10mil+ rows at max, and this
machine will sustain about 25mbps of insert/update/delete traffic 24/7 -
365, will I be saving much by partitioning data like that?

--
-Matt

<http://twiki.spimageworks.com/twiki/bin/view/Software/CueDevelopment>

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-19-2008, 11:33 AM
Scott Marlowe
 
Posts: n/a
Default Re: db performance/design question

On 9/12/07, Matt Chambers <chambers@imageworks.com> wrote:
>
>
> I'm designing a system that will be doing over a million inserts/deletes on
> a single table every hour. Rather than using a single table, it is possible
> for me to partition the data into multiple tables if I wanted to, which
> would be nice because I can just truncate them when I don't need them. I
> could even use table spaces to split the IO load over multiple filers. The
> application does not require all this data be in the same table. The data
> is fairly temporary, it might last 5 seconds, it might last 2 days, but it
> will all be deleted eventually and different data will be created.
>
> Considering a single table would grow to 10mil+ rows at max, and this
> machine will sustain about 25mbps of insert/update/delete traffic 24/7 -
> 365, will I be saving much by partitioning data like that?


This is the exact kind of application for which partitioning shines,
especially if you can do the inserts directly to the partitions
without having to create rules or triggers to handle it. If you have
to point at the master table, stick to triggers as they're much more
efficient at slinging data to various sub tables.

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-19-2008, 11:33 AM
Charles.Hou
 
Posts: n/a
Default Re: db performance/design question

On 9 13 , 5 58 , scott.marl...@gmail.com ("Scott Marlowe") wrote:
> On 9/12/07, Matt Chambers <chamb...@imageworks.com> wrote:
>
>
>
> > I'm designing a system that will be doing over a million inserts/deletes on
> > a single table every hour. Rather than using a single table, it is possible
> > for me to partition the data into multiple tables if I wanted to, which
> > would be nice because I can just truncate them when I don't need them. I
> > could even use table spaces to split the IO load over multiple filers. The
> > application does not require all this data be in the same table. The data
> > is fairly temporary, it might last 5 seconds, it might last 2 days, but it
> > will all be deleted eventually and different data will be created.

>
> > Considering a single table would grow to 10mil+ rows at max, and this
> > machine will sustain about 25mbps of insert/update/delete traffic 24/7 -
> > 365, will I be saving much by partitioning data like that?

>
> This is the exact kind of application for which partitioning shines,
> especially if you can do the inserts directly to the partitions
> without having to create rules or triggers to handle it. If you have
> to point at the master table, stick to triggers as they're much more
> efficient at slinging data to various sub tables.
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/docs/faq

another question, how do i know the database performance? yesterday,
my database had something happened. The database status is running,
but can't do any operation , like insert/delete/query. i must stop the
postgresql service, and then start it.
have any way to know what's the maximum loading of database?

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 05:55 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com