poor performance with Context Switch Storm at TPC-W.

From: Katsuhiko Okano <okano(dot)katsuhiko(at)oss(dot)ntt(dot)co(dot)jp>
To: pgsql-hackers(at)postgresql(dot)org
Subject: poor performance with Context Switch Storm at TPC-W.
Date: 2006-07-11 11:09:24
Message-ID: 200607112009.FED09315.TLPPUBIBOPuVLJL@oss.ntt.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Hi,All.

The problem has occurred in my customer.
poor performance with Context Switch Storm occurred
with the following composition.
Usually, CS is about 5000, WIPS=360.
when CSStorm occurrence, CS is about 100000, WIPS=60 or less.
(WIPS = number of web interactions per second)

It is under investigation using the patch
which collects a LWLock.

I suspected conflict of BufMappingLock.
but, collected results are seen,
occurrence of CSStorm and the increase of BufMappingLock counts
seem not to correspond.
Instead, SubtransControlLock and SubTrans were increasing.
I do not understand what in the cause of CSStorm.

[DB server]*1
Intel Xeon 3.0GHz*4(2CPU * H/T ON)
4GB Memory
Red Hat Enterprise Linux ES release 4(Nahant Update 3)
Linux version 2.6.9-34.ELsmp
PostgreSQL8.1.3 (The version 8.2(head-6/15) was also occurred)
shared_buffers=131072
temp_buffers=1000
max_connections=300

[AP server]*2
200 connection pooling.
TPC-W model workload

[Clinet]*4
TPC-W model workload

(1)
The following discussion were read.
http://archives.postgresql.org/pgsql-hackers/2006-05/msg01003.php
From: Tom Lane <tgl ( at ) sss ( dot ) pgh ( dot ) pa ( dot ) us>
To: josh ( at ) agliodbs ( dot ) com
Subject: Re: Further reduction of bufmgr lock contention
Date: Wed, 24 May 2006 15:25:26 -0400

If there is a patch for investigation or a technique,
would someone show it to me?

(2)
It seems that much sequential scan has occurred at CSStorm.
When reading a tuple, do the visible satisfy check.
it seems to generate the subtransaction for every transaction.
How much is a possibility that
the LWLock to a subtransaction cause CSStorm?

best regards.
--------
Katsuhiko Okano
okano katsuhiko _at_ oss ntt co jp

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Hallgren 2006-07-11 12:10:19 Re: Three weeks left until feature freeze
Previous Message Charles Duffy 2006-07-11 07:25:33 putting CHECK_FOR_INTERRUPTS in qsort_comparetup()

Browse pgsql-patches by date

  From Date Subject
Next Message Qingqing Zhou 2006-07-11 13:06:13 Re: poor performance with Context Switch Storm at TPC-W.
Previous Message Charles Duffy 2006-07-11 07:25:33 putting CHECK_FOR_INTERRUPTS in qsort_comparetup()