From: rihad <rihad@mail.ru>
To: pgsql-general General <pgsql-general@postgresql.org>
Subject: Quere keep using temporary files
Date: Fri, 25 Oct 2019 12:22:58 +0400
Message-ID: <2c38ebb8-977e-926b-4842-5cf31c4059b2@mail.ru> (raw)
Hi, we frequently run many query involving XML that use a smallish
temporary file, despite having increased local work_mem in that
transaction to 16GB. FreeBSD's top shows that the memory isn't actually
being used - it remains free. Basically many such queries are run within
a single transaction:
LOG: temporary file: path "base/pgsql_tmp/pgsql_tmp92452.1079", size 166518
STATEMENT: DELETE FROM "foo" WHERE ((col1, col2, col3) in (select col1,
col2, col3 from foo_xml_v2('<here goes xml-formatted blob>'))) AND
"foo"."col_id" IN ($1, $2, $3, $4, $5, $6, $7, $8, $9)
It looks like increasing work_mem doesn't help. Surely 16GB is enough to
cover all these small temp files?
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: rihad@mail.ru
Subject: Re: Quere keep using temporary files
In-Reply-To: <2c38ebb8-977e-926b-4842-5cf31c4059b2@mail.ru>
References: <2c38ebb8-977e-926b-4842-5cf31c4059b2@mail.ru>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox