query against pg_locks leads to large memory alloc

From: Dave Owens <dave(at)teamunify(dot)com>
To: postgres performance list <pgsql-performance(at)postgresql(dot)org>
Subject: query against pg_locks leads to large memory alloc
Date: 2014-08-18 21:01:30
Message-ID: CA+OQrzhdtpC-9enDpY_PTue3_eh9xxmP-z51fJHFqezvhJ-9Nw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Hi,

I have a tool that is trying to collect stats from postgres (v9.1.13).
postgres attempts to allocate more memory than is allowed:

SELECT mode, count(mode) AS count FROM pg_locks GROUP BY mode ORDER BY mode;
ERROR: invalid memory alloc request size 1459291560

Memory-related configs from the server:

shared_buffers = 10000MB
work_mem = 15MB
maintenance_work_mem = 400MB
effective_cache_size = 50000MB
max_locks_per_transaction = 9000
max_pred_locks_per_transaction = 40000

The machine is running CentOS 6, a 32-core AMD 6276 processor, and is
configured with 64GB of memory. Transparent Huge Pages are disabled
:-)

Thanks in advance for your time and expertise.

Dave Owens

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Matheus de Oliveira 2014-08-18 21:21:59 Re: query against pg_locks leads to large memory alloc
Previous Message Tom Lane 2014-08-18 03:49:42 Re: select on index column,why PG still use seq scan?