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 1iCd2K-0000NS-Sd for pgsql-general@arkaria.postgresql.org; Tue, 24 Sep 2019 05:06:53 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iCd2H-00017b-H2 for pgsql-general@arkaria.postgresql.org; Tue, 24 Sep 2019 05:06:49 +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 1iCd2H-00017U-3H for pgsql-general@lists.postgresql.org; Tue, 24 Sep 2019 05:06:49 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iCd2D-0003f1-Nm for pgsql-general@postgresql.org; Tue, 24 Sep 2019 05:06:47 +0000 Received: by mail-wr1-x442.google.com with SMTP id n14so321922wrw.9 for ; Mon, 23 Sep 2019 22:06:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec-at.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:cc:date:in-reply-to:references :user-agent:mime-version:content-transfer-encoding; bh=LGA3ZS3HYqSh790teZgaPAQ0r3NmBVSpu47qvhMNFeg=; b=rsdDznQkf3Y4u//Cng3WU0Z80NHiIPj5FYr55+lnwQPW+BeiTuIGoZX/X4FVhiBHzP 0qExmRpJlY0cKj4jfXx0gT7YERurUDOfRsd1hcbLO14+VhXQ0PcF3rljE6uJy0x0pRdJ +HsrcgFweemKUqvqDAAUnVMqDAissmCoqbjfzRmt3YMdWKW69105kckTXE+M84AHWKuO bKRBoY81PSi0gdrvDXzoX25b+69ZROzixSwfVMYxiT02UWy/jJ0GToC3mB2np8AN6gUL Hr/LWdSxXpRH2DreU/LusvJ5gRtWu4miFQK7xtfFCQgQ2IjKb9a1A7Tu9KUisbpkpgjX DWig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=LGA3ZS3HYqSh790teZgaPAQ0r3NmBVSpu47qvhMNFeg=; b=fcSc96g7nvTP5ybrEoA/c5A6l3pR3oCHGG1giI0LI1O0X+XKSqBDELsPIewi5Qlnx3 n0MYbfZv2T6XtY96hztM8O7xeAQYLX1SqsQxGGqs7YzQAZG4D+b3E8nPM6Qloc8cJYCc +jAAFGjEEoI7qsck7EOm8gQdC7RcH/HnHwdxMhdY4z3gjpbnkBAyzKhR8fOV8LnbDa48 8Y3RjQKxrOXTPBtxl7a6U3zjz6LuLu5Mj1dpI0XOjbWq9e4SYCAEjg3krcwwJDb3EXzB eiyx1cRzPn3lk83LeOUqI1/K0UZ0TATgFLsHFlJkIp2FPbh1VJYUrwchKpxgG2aXInrL RxzQ== X-Gm-Message-State: APjAAAW7xGwPeqdZrEt7Pqmv1P8r7sHz/TBTDtTiQp8HpGt9GYqbFf6t ihfbNk32GPEHCQ50/pFWQdLGRQ== X-Google-Smtp-Source: APXvYqx9YavTS/3Cod5NU6Qry7+xGbpuQZB79IXuVTHZsgWy8R4ic6Qdh/sGJUd0q2uP6cyq+jcf8g== X-Received: by 2002:adf:f790:: with SMTP id q16mr646355wrp.164.1569301604563; Mon, 23 Sep 2019 22:06:44 -0700 (PDT) Received: from localhost.localdomain (mobiledyn-185-69-244-32.mrsn.at. [185.69.244.32]) by smtp.gmail.com with ESMTPSA id r9sm622630wra.19.2019.09.23.22.06.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Sep 2019 22:06:43 -0700 (PDT) Message-ID: Subject: Re: Autovacuum lock conflict From: Laurenz Albe To: Michael Lewis Cc: Christophe Escobar , pgsql-general Date: Tue, 24 Sep 2019 07:06:42 +0200 In-Reply-To: References: <5e0018a7e73aad15d08006b6ac158742e1561294.camel@cybertec.at> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.32.4 (3.32.4-1.fc30) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Mon, 2019-09-23 at 13:53 -0600, Michael Lewis wrote: > > - For tables that receive only INSERTs, schedule a regular VACUUM > > with "cron" or similar. Unfortunately, PostgreSQL isn't very > > smart > > about vacuuming insert-only tables. > > > What is the need to vacuum on an insert only table? Does that just > maintain the freespace map? No, the idea is to get rows frozen *before* autovacuum launches an anti-wraparound vacuum. You could launch VACUUM (FREEZE) for best effect. This way you can schedule the operation so that it doesn't interfere with your other activities. Yours, Laurenz Albe -- Cybertec | https://www.cybertec-postgresql.com