Re: Temporary tablespaces on a RAM disk

From: "Daniel Westermann (DWE)" <daniel(dot)westermann(at)dbi-services(dot)com>
To: Jerry Sievers <gsievers19(at)comcast(dot)net>, Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
Cc: "pgsql-general(at)lists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Temporary tablespaces on a RAM disk
Date: 2020-03-18 07:17:16
Message-ID: GV0P278MB0017BB2892CA6B974256E492D2F70@GV0P278MB0017.CHEP278.PROD.OUTLOOK.COM
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> writes:

>> On Tue, 2020-03-17 at 19:57 +0000, Daniel Westermann (DWE) wrote:
>>
>>> >> is someone using temporary tablespaces on a RAM disk ? Any experiences with that?
>>> >> I did some quick tests and checked the archives but could not find any
>>> >> information that either confirmed it is a bad idea nor the opposite.
>>>
>>> >Taking a step back, wouldn't it be better to increase "work_mem"
>>> >and "temp_buffers" and set "temp_file_limit", so that temporary
>>> >files are avoided whenever possible and temporary tables are cached?
>>>
>>> I don't think you can avoid that for all cases, especially when working
>>> with large data sets. That was one of the reasons for my initial question.
>>
>> But with your proposed setup, any query that needs more temp space
>> than your RAM disk has will fail. I don't think that is good for large
>> data sets.

>Perhaps not, but disk filling on the same volume as WAL is also a
>serious problem in case the process that eventually took the storage to
>100% and got an ENoSpace was the WAL write :-)

>Er, but any standard 1-tablespace configuration is at risk of that,
>generally.

Thank you all for your input.

Regards
Daniel

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Guillaume Lelarge 2020-03-18 10:31:43 Re: How can I set all constraints to be deferrable for a DB/schema
Previous Message David Gauthier 2020-03-18 03:14:03 How can I set all constraints to be deferrable for a DB/schema