Re: Help: massive parallel update to the same table

From: "Nicholson, Brad (Toronto, ON, CA)" <bnicholson(at)hp(dot)com>
To: Red Maple <redmapleleaf(at)gmail(dot)com>, "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Help: massive parallel update to the same table
Date: 2011-03-18 14:23:57
Message-ID: 2626AEE4839D064CB0472A3814DC403F46D2081335@GVW1092EXB.americas.hpqcorp.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

>From: pgsql-performance-owner(at)postgresql(dot)org [mailto:pgsql-performance-owner(at)postgresql(dot)org] On Behalf Of Red Maple
>Sent: Friday, March 18, 2011 9:05 AM
>To: pgsql-performance(at)postgresql(dot)org
>Subject: [PERFORM] Help: massive parallel update to the same table
>
>Hi all,
>
>Our system has a postgres database that has a table for statistic which is updated every hour by about 10K clients. Each client only make update to its own row in the table. So far >I am only seeing one core out of eight cores on my server being active which tells me that the update is being done serial instead of being parallel. Do you know if there is a way >for me to make these independent updates happen in parallel?
>
>Thank you, your help is very much appreciated!

If they are all happening on one core, you are probably using one DB connection to do the updates. To split them across multiple cores, you need to use multiple DB connections. Be careful if/when you restructure things to filter these requests into a reasonable number of backend DB connections - turning a huge number of clients loose against a DB is not going end well.

Brad.

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Kevin Grittner 2011-03-18 14:28:02 Re: Help: massive parallel update to the same table
Previous Message Reid Thompson 2011-03-18 14:05:33 Re: Help with Query Tuning