Re: [HACKERS] Simmultanous Connections (fwd)
От | The Hermit Hacker |
---|---|
Тема | Re: [HACKERS] Simmultanous Connections (fwd) |
Дата | |
Msg-id | Pine.BSF.4.21.0001101236110.18498-100000@thelab.hub.org обсуждение исходный текст |
Ответ на | Simmultanous Connections (fwd) (Vince Vielhaber <vev@michvhf.com>) |
Список | pgsql-hackers |
On Mon, 10 Jan 2000, Vince Vielhaber wrote: > 1. I have read the Q&A for postgreSQL and would like to know the > difference between a temporary and a permanant connection. Do you have > a connection when you open the database or only when the frontend > sends a job to the backend? If 32 people are running a module that > opens a database is that 32 connections or will it vary as users read > and write to the database? You will have 32 connections open to the backend ... > 2. I saw in the Q&A that to run more than 32 simmultanous connects > could be a big drain on our re- sources. Our Linux boxes , in general, > are Intel 166 to 500s, 128MG of RAM and 6.2 to 13 GIG. Can anyone > tell me roughly how much resources per connection does PostgreSQL use? It depends on what the connections are doing...if someone is doing a 'SELECT...ORDER BY', it will take more resources then if you are doing something that doesn't involve any sort routines... > 3. If I have 90 teachers posting grades at the same time, (the grade > posting program opens 5 dif- ferent databases) and 25 secretaries and > administrators poking around in assorted databases looking at > information, will postgresql handle that much traffic? 5 different databases, vs 5 different tables? 5 different databases will mean 90 x 5 (450) connections opened up...whereas 5 tables would be just 90 connections... ... but, either way, will it handle that much traffic? give it enough RAM, and I personally don't see why not, but I've yet to hit *that* kind of a load on it. Right now, I have PostgreSQL setup to handle several databases, and the postmaster processes each take up ~4-5Meg: hub> ps aux | grep data pgsql 895 0.0 0.2 4508 1416 d0- S 6:52AM 0:00.98 /home/database/v pgsql 896 0.0 0.2 3976 1308 d0- I 6:52AM 0:00.02 /home/database/v When I open up a session/connection to a database, I'm seeing: pgsql 71041 5.1 0.4 5028 3492 ?? R 11:40AM 0:00.54 /home/database/v pgsql 71032 0.0 0.4 4992 3148 ?? S 11:40AM 0:00.02 /home/database/v pgsql 71034 0.0 0.4 4980 2976 ?? S 11:40AM 0:00.02 /home/database/v Now, I always get this backwards/confused, but...the first value (ie. 4508) is the binary size, which is mis-informed due to the use of shared libraries... the important one is the second value (ie. 1416), which, again, if I recall correctly, is the datasize...for the udmsearch database, just starting up 'psql udmsearch', each database is taking <3.5Meg...depending on the sizes of your queries and whatnot, figure that I'd need 3.5Meg*450 (~1.5gig) of memory on this machine to handle it (I have half of that now)...bear in mind that not all 450 connections would be active, so there is room for some processes to be swap'd out and whatnot.. My personal opinion is that there isn't anything that PostgreSQL hasn't been able to handle so far, to the best of my knowledge...my next step for my system is to go dual-processor, and bring on a full gig of RAM, but my machine also does alot more then just PostgreSQL :) Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy Systems Administrator @ hub.org primary: scrappy@hub.org secondary: scrappy@{freebsd|postgresql}.org
В списке pgsql-hackers по дате отправления: