Re: Check memory consumption of postgresql query

Поиск
Список
Период
Сортировка
От Matheus de Oliveira
Тема Re: Check memory consumption of postgresql query
Дата
Msg-id CAJghg4+1mcK1KdunxZHYbL2hQgDz-C2XohKZPbBnQVCO_+oGig@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Check memory consumption of postgresql query  (Phan Công Minh <cphan@hsr.ch>)
Список pgsql-performance

On Mon, May 12, 2014 at 4:02 AM, Phan Công Minh <cphan@hsr.ch> wrote:
Thank you for your response. I check the article (http://www.depesz.com/2012/06/09/how-much-ram-is-postgresql-using/) and it seems to work with general process as well.
However does it have anyway to calculate the memory used by single query, not the whole postgresql process?

You can check only the /proc/<pid>/ for the backend you are interested in. Also, an EXPLAIN ANALYZE of your qurey will show memory used by some operations (like sort, hash, etc.), those are limited by the work_mem parameter, so if you are working on benchmarks, you may want to tune that properly.

Regards,
--
Matheus de Oliveira
Analista de Banco de Dados
Dextra Sistemas - MPS.Br nível F!
www.dextra.com.br/postgres

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

Предыдущее
От: Jeff Janes
Дата:
Сообщение: Re: 9.2.4 vs 9.3.0 query planning (sort merge join vs hash join)
Следующее
От: Michael Stone
Дата:
Сообщение: Re: Specifications for a new server