Re: Is there a way to limit CPU usage per user

Поиск
Список
Период
Сортировка
От Scott Marlowe
Тема Re: Is there a way to limit CPU usage per user
Дата
Msg-id 1139503386.22740.110.camel@state.g2switchworks.com
обсуждение исходный текст
Ответ на Re: Is there a way to limit CPU usage per user  (Merlin Moncure <mmoncure@gmail.com>)
Список pgsql-general
On Wed, 2006-02-08 at 15:42, Merlin Moncure wrote:
> > Is there a way to limit user's CPU resource specially on "SELECT" query ?
> >
> > I hava a table with a lot of rows inside, if one sloopy DB users do a
> > "SELECT * FROM bigtable"
> > then CPU resource will go near 99% and this action will surely affect
> > the other database performance ...
> >
> Yes, the answer is not to write the query in the first place :-).  you
> can implement cursors, do client side browsing, or other techiniques
> to handle this problem more elegantly.
>
> try to follow rule of thumb to return minimal amount of data necessary
> to the client.

Note that another useful tip here is to use slony to produce as many
replicants as needed to handle that kind of thing.

We have our production pgsql machines in a slony setup, with pg01 being
accessible by the application that inserts and updates the data, and all
reporting apps hit pg02 and up to do selects and such.

В списке pgsql-general по дате отправления:

Предыдущее
От: Shelby Cain
Дата:
Сообщение: Re: [ODBC] Problem using ODBC from .NET framework
Следующее
От: Tom Lane
Дата:
Сообщение: Re: PQputline error with pg_restore