Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ju13y-0006Nc-Tm for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Jul 2020 22:00:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ju13w-0008BH-Kl for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Jul 2020 22:00:08 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ju13w-0008BA-D6 for pgsql-hackers@lists.postgresql.org; Fri, 10 Jul 2020 22:00:08 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ju13u-0004Bb-Cr for pgsql-hackers@postgresql.org; Fri, 10 Jul 2020 22:00:07 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 06ALxxSp2165607; Fri, 10 Jul 2020 17:59:59 -0400 From: Tom Lane To: Stephen Frost cc: Peter Geoghegan , Jeff Davis , Alvaro Herrera , Andres Freund , Bruce Momjian , Robert Haas , David Rowley , Justin Pryzby , Melanie Plageman , Tomas Vondra , "pgsql-hackers@postgresql.org" Subject: Re: Default setting for enable_hashagg_disk In-reply-to: <20200710215012.GN12375@tamriel.snowman.net> References: <20200708140037.GI3125@tamriel.snowman.net> <99b047386525b87df1e611335c2e57a6cdef346b.camel@j-davis.com> <20200709140330.GO3125@tamriel.snowman.net> <20200709225840.GE12375@tamriel.snowman.net> <20200710000842.GF12375@tamriel.snowman.net> <20200710141714.GI12375@tamriel.snowman.net> <20200710215012.GN12375@tamriel.snowman.net> Comments: In-reply-to Stephen Frost message dated "Fri, 10 Jul 2020 17:50:13 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2165605.1594418399.1@sss.pgh.pa.us> Date: Fri, 10 Jul 2020 17:59:59 -0400 Message-ID: <2165606.1594418399@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Stephen Frost writes: > I don't see hash_mem as being any kind of proper fix- it's just punting > to the user saying "we can't figure this out, how about you do it" and, > worse, it's in conflict with how we already ask the user that question. > Turning it into a multiplier doesn't change that either. Have you got a better proposal that is reasonably implementable for v13? (I do not accept the argument that "do nothing" is a better proposal.) I agree that hash_mem is a stopgap, whether it's a multiplier or no, but at this point it seems difficult to avoid inventing a stopgap. Getting rid of the process-global work_mem setting is a research project, and one I wouldn't even count on having results from for v14. In the meantime, it seems dead certain that there are applications for which the current behavior will be problematic. hash_mem seems like a cleaner and more useful stopgap than the "escape hatch" approach, at least to me. regards, tom lane