From: | "Sergey E(dot) Koposov" <math(at)sai(dot)msu(dot)ru> |
---|---|
To: | Poul Møller Hansen <freebsd(at)pbnet(dot)dk> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Setting up a database for 10000 concurrent users |
Date: | 2005-09-06 00:17:54 |
Message-ID: | Pine.LNX.4.44.0509060358330.7172-100000@lnfm1.sai.msu.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Mon, 5 Sep 2005, [UTF-8] Poul Mц╦ller Hansen wrote:
> I'm trying to setup a database for 10000 concurrent users for a test.
> I have a system with 1GB of RAM where I will use 512MB for PostgreSQL.
> It is running SuSE 9.3
>
> I have changed SHMMAX & SHMALL
> echo "536870912" >/proc/sys/kernel/shmmax
> echo "536870912" >/proc/sys/kernel/shmall
>
> and max_connections = 10000 in postgresql.conf
>
> When trying to start the database server it leaves this in the log.
> Calculated the values should be
> SEMMNI = 10000 / 16
> SEMMNS = (10000 / 16) * 17 "plus room for other applications" How much
> should that be ?
> And where can I change those values on a 2.6 kernel ?
>
The file /proc/sys/kernel/sem contains 4 numbers
SEMMSL The maximum semaphores per semaphore set.
SEMMNS A system-wide limit on the number of
semaphores in all semaphore sets.
SEMOPM The maximum number of operations that may
be specified in a semop(2) call.
SEMMNI A system-wide limit on the maximum number
of semaphore identifiers.
Look "man proc"
So just do something like
echo "250 32000 32 16000" > /proc/sys/kernel/sem
(compute the exact numbers by yourself)
But I really doubt that it it possible/reasonable to have 10000
simultaneous connections.
Also you can setup the semaphore numbers using sysctl
sysctl -w kernel.sem="250 32000 32 16000"
Regards,
Sergey
*****************************************************
Sergey E. Koposov
Max-Planck Institut fuer Astronomie
Web: http://lnfm1.sai.msu.ru/~math
E-mail: math(at)sai(dot)msu(dot)ru
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2005-09-06 00:51:13 | Re: Bug or ? |
Previous Message | Klint Gore | 2005-09-05 23:26:39 | Re: Debug plpgSQL stored procedures |