Hi Guillaume, Now i disable Hyper Threading in BIOS, and "context switch storms" disappeared. (when i look with command sar -t) I decreased work_mem parameter to 32768. My CPU load is better. But it is still too high, in example : top - 16:27:05 up 9:13, 3 users, load average: 45.37, 43.43, 41.43 Tasks: 390 total, 26 running, 363 sleeping, 0 stopped, 1 zombie Cpu(s): 89.5% us, 9.8% sy, 0.0% ni, 0.0% id, 0.0% wa, 0.2% hi, 0.4% si Mem: 2076404k total, 2039552k used, 36852k free, 40412k buffers Swap: 1954312k total, 468k used, 1953844k free, 1232000k cached PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 30907 postgres 16 0 537m 51m 532m R 20.4 2.5 1:44.73 postmaster 25631 postgres 16 0 538m 165m 532m R 17.4 8.2 8:43.76 postmaster 29357 postgres 16 0 537m 311m 532m R 17.4 15.3 0:26.47 postmaster 32294 postgres 16 0 535m 86m 532m R 14.9 4.3 0:04.97 postmaster 31406 postgres 16 0 536m 180m 532m R 14.4 8.9 0:22.04 postmaster 31991 postgres 16 0 535m 73m 532m R 14.4 3.6 0:08.21 postmaster 30782 postgres 16 0 536m 205m 532m R 14.0 10.1 0:19.63 postmaster Tomorrow morning i plan to add 2Go RAM in order to test difference with my actual config. Have you another ideas ? Best Regards, -- Jérôme, python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for p in 'sioneb@xxxxxxxxxxxxxxxxxxxx'.split('@')])" Le vendredi 15 septembre 2006 à 00:24 +0200, Guillaume Smet a écrit : > On 9/14/06, Jérôme BENOIS <benois@xxxxxxxxxxxxxxxxxxxx> wrote: > > Yes i have a lot of users ;-) > > So your work_mem is probably far too high (that's what I told you in > my first message) and you probably swap when you have too many users. > Remember that work_mem can be used several times per query (and it's > especially the case when you have a lot of sorts). > When your load is high, check your swap activity and your io/wait. top > gives you these information. If you swap, lower your work_mem to 32 MB > for example then see if it's enough for your queries to run fast (you > can check if there are files created in the $PGDATA/base/<your > database oid>/pg_tmp) and if it doesn't swap. Retry with a > lower/higher value to find the one that fits best to your queries and > load. > > > I agree but by moment DB Server is so slow. > > Yep, that's the information that was missing :). > > > what's means "HT" please ? > > Hyper threading. It's usually not recommended to enable it on > PostgreSQL servers. On most servers, you can disable it directly in > the BIOS. > > -- > Guillaume > > ---------------------------(end of broadcast)--------------------------- > TIP 1: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@xxxxxxxxxxxxxx so that your > message can get through to the mailing list cleanly >
Attachment:
signature.asc
Description: Ceci est une partie de message =?ISO-8859-1?Q?num=E9riquement?= =?ISO-8859-1?Q?_sign=E9e?=