Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iB5MU-0003H3-9Q for pgsql-performance@arkaria.postgresql.org; Thu, 19 Sep 2019 22:57:18 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iB5MS-00078J-VI for pgsql-performance@arkaria.postgresql.org; Thu, 19 Sep 2019 22:57:16 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iB5MS-000785-MF for pgsql-performance@lists.postgresql.org; Thu, 19 Sep 2019 22:57:16 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iB5MQ-0006GZ-HS for pgsql-performance@lists.postgresql.org; Thu, 19 Sep 2019 22:57:16 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id x8JMvBeG018658; Thu, 19 Sep 2019 18:57:11 -0400 From: Tom Lane To: =?UTF-8?Q?Lu=c3=ads_Roberto_Weck?= cc: Michael Lewis , pgsql-performance@lists.postgresql.org Subject: Re: Slow query on a one-tuple table In-reply-to: References: <24571.1568910502@sss.pgh.pa.us> <774d6080-d6d7-e9e7-7351-9a412c7d5956@siscobra.com.br> <18ae8108-acaf-e9cc-96a9-ab20f4147f5a@siscobra.com.br> <35df2bd8-4c7c-7ace-6bdc-d6d97a101a14@siscobra.com.br> <1980a708-ed4a-6fc6-2792-33c07b07d704@siscobra.com.br> Comments: In-reply-to =?UTF-8?Q?Lu=c3=ads_Roberto_Weck?= message dated "Thu, 19 Sep 2019 19:46:46 -0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <18656.1568933831.1@sss.pgh.pa.us> Date: Thu, 19 Sep 2019 18:57:11 -0400 Message-ID: <18657.1568933831@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk =?UTF-8?Q?Lu=c3=ads_Roberto_Weck?= writes: > As fas as autovacuum options, this is what I'm using: > autovacuum_vacuum_scale_factor=0, Ugh ... maybe I'm misremembering, but I *think* that has the effect of disabling autovac completely. You don't want zero. Check in pg_stat_all_tables.last_autovacuum to see if anything is happening. If the dates seem reasonably current, then I'm wrong. regards, tom lane