Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ujDXi-004YEm-8C for pgsql-hackers@arkaria.postgresql.org; Tue, 05 Aug 2025 09:01:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1ujDXh-008bSQ-7i for pgsql-hackers@arkaria.postgresql.org; Tue, 05 Aug 2025 09:01:09 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ujDVR-008Yub-Jt for pgsql-hackers@lists.postgresql.org; Tue, 05 Aug 2025 08:58:49 +0000 Received: from mail-ej1-x62f.google.com ([2a00:1450:4864:20::62f]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1ujDVO-000pZR-1H for pgsql-hackers@lists.postgresql.org; Tue, 05 Aug 2025 08:58:48 +0000 Received: by mail-ej1-x62f.google.com with SMTP id a640c23a62f3a-af934d7c932so573914266b.3 for ; Tue, 05 Aug 2025 01:58:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec.at; s=google; t=1754384326; x=1754989126; darn=lists.postgresql.org; h=message-id:date:content-id:mime-version:comments:references :in-reply-to:subject:cc:to:from:from:to:cc:subject:date:message-id :reply-to; bh=iW1Wjq6HFfpm4YC+fgHjR2O8XHeWUlyOooax19OFn9Q=; b=cq0+RpTk2CvDF7/oOnAx+WL08tFmSlvIHDvEA/DwFt/i/fchM/ZrjfsnT/uqouo8Al wMvIEQihVAHY/QMR3TiY66DofKx180G2cGcdBrqihmLBB8MfgakR49+vlVyTyLZvMC7z 5yqwcYVmojrl6nFr48eW5zgJkNgPmFJa/wT9DEu1Gt894qXGEgIAZvaJ7zE8YAOYhpM+ Tbvga4YM6ko2cmRa/cu8aErezixVDir5CZ/5jM+usYRCW+bQotxYX+gWyf1pncTiCTWa 8S9+3SpkW5H0z+AAbigxm7lgXYGu0CrvPv3BGV2ZeatxSecJq3XzkyYoVpdvCoKEGHHp 0RyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1754384326; x=1754989126; h=message-id:date:content-id:mime-version:comments:references :in-reply-to:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=iW1Wjq6HFfpm4YC+fgHjR2O8XHeWUlyOooax19OFn9Q=; b=r8WyEsRLRlhta75rYLhmhO4IwUoh3qBQb93QpKyiRu976UlZRXnYS1NXj7wHtRcCCP TUwfJB9a8zkk/oSGHLCDy7zEbZ15i8fz2v23rIzySX6GHM32Dqgh6pzoYDVYEpEZq2iR ad/dbqQ1YUCjKYd9ibsAKx9mS133NI3NwyPQsev3y+ttwJzXGjObu+CcREJthlNWXSBw sriElpdXextlGIWJ7AB9UYzc3vjnFefEj73dumC/Y2x6hJLOCAbnfN7tDTytVl7RTlJR xoR/FHtOI0NjDP8tP+LLoVu4zkd3w8M6Pp6S3DTevi157kiULC6Lc6nHSQFIAq8Jvb5w ysCg== X-Gm-Message-State: AOJu0Yyqj9laP+IqnkmBtFrVVORbWuas7YIX/i4L1kKd1mlLEa7h/vy7 f3ATKlaQmeRsE3LX6miGzxjQwq8eu00A5aLaF5HDdjGIasJV/fDf5EDsRv7DqCJF7HPpmccyUTM aKvpN X-Gm-Gg: ASbGncsTyZWriZnacMvoRDkFmWVqAsF0JTsrIMNDNLVzbg4IUydyYeKzw8falkq6/UU yWeXQrcZd85wBIcISQio8+zch3V9Rqnxi242lMna39eSH1PXpIqrPHwofkROEtfia8hbdTSDgtp 4REBtcoVILlW32Og1IuayWm1d3EnUVmyQ4nowRLLpiaiffpIKCFfOlJtImXOOth2v8+9wl2aNZl TluZZtCIKFAK1lGRYn7fJM+yzML4Se+A9b7APfXTQ2+WfhGcFfiLELTtTbOqpSeEEhruhrN5aI9 aGnEV42LYfG7YXFX3lVgz9fMYjGFhN8TjJod1VGJsLI895NQjvJwDfOdx3H7f7pRKUE3Ed7VwZS NfKmrk2awHK5IKvI2s2gtKz3yj8+q3+oEdYfacH7pPEMcrxw= X-Google-Smtp-Source: AGHT+IH+MJL065rs+62Rl1mJ7BeaOcEVPaRU+PaHzHyqoZhkmb7kSiDxs9lYF49qBrer6f7eGNqDbg== X-Received: by 2002:a17:907:96ab:b0:ae3:7c8c:351d with SMTP id a640c23a62f3a-af9401da95dmr1427719666b.56.1754384325694; Tue, 05 Aug 2025 01:58:45 -0700 (PDT) Received: from localhost (109-81-168-173.rct.o2.cz. [109.81.168.173]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-af91a0771basm860446966b.29.2025.08.05.01.58.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Aug 2025 01:58:45 -0700 (PDT) From: Antonin Houska To: Alvaro Herrera cc: Pg Hackers Subject: Re: Adding REPACK [concurrently] In-reply-to: <202507262156.sb455angijk6@alvherre.pgsql> References: <202507262156.sb455angijk6@alvherre.pgsql> Comments: In-reply-to Alvaro Herrera message dated "Sat, 26 Jul 2025 23:56:04 +0200." X-Mailer: MH-E 8.6+git; nmh 1.8; GNU Emacs 28.3 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <11035.1754384324.1@localhost> Date: Tue, 05 Aug 2025 10:58:44 +0200 Message-ID: <11036.1754384324@localhost> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Alvaro Herrera wrote: > I made a few changes from Antonin's original at [2]. First, I modified > the grammar to support "REPACK [tab] USING INDEX" without specifying the > index name. With this change, all possibilities of the old commands are > covered, ... > Here's a list of existing commands, and how to write them in the current > patch's proposal for REPACK: > > -- re-clusters all tables that have a clustered index set > CLUSTER -> REPACK USING INDEX > > -- clusters the given table using the given index > CLUSTER tab USING idx -> REPACK tab USING INDEX idx > > -- clusters this table using a clustered index; error if no index clustered > CLUSTER tab -> REPACK tab USING INDEX > > -- vacuum-full all tables > VACUUM FULL -> REPACK > > -- vacuum-full the specified table > VACUUM FULL tab -> REPACK tab > Now that we want to cover the CLUSTER/VACUUM FULL completely, I've checked the options of VACUUM FULL. I found two items not supported by REPACK (but also not supported by by CLUSTER): ANALYZE and SKIP_DATABASE_STATS. Maybe just let's mention that in the user documentation of REPACK? (Besides that, VACUUM FULL accepts TRUNCATE and INDEX_CLEANUP options, but I think these have no effect.) -- Antonin Houska Web: https://www.cybertec-postgresql.com