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.96) (envelope-from ) id 1wVcZf-0025Re-05 for pgsql-general@arkaria.postgresql.org; Fri, 05 Jun 2026 21:59:31 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wVcZd-00EvIq-32 for pgsql-general@arkaria.postgresql.org; Fri, 05 Jun 2026 21:59:29 +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.96) (envelope-from ) id 1wVcZd-00EvIh-1s for pgsql-general@lists.postgresql.org; Fri, 05 Jun 2026 21:59:29 +0000 Received: from mail-wm1-x331.google.com ([2a00:1450:4864:20::331]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wVcZb-00000001Isy-2VFn for pgsql-general@lists.postgresql.org; Fri, 05 Jun 2026 21:59:28 +0000 Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-490a765d410so25013495e9.1 for ; Fri, 05 Jun 2026 14:59:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec.at; s=google; t=1780696761; x=1781301561; darn=lists.postgresql.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id:from:to:cc:subject:date :message-id:reply-to; bh=zc/n8iXQaUil2qy8JG0M/lXfN7O6sI37sHV4EIazQEc=; b=gq5C5nk97HNHjKgcU199hZbgnUyn0jGtH3XxRgf3WqnKtxzoexHLZN1Zil3EQwm6FK wKL1YhRkaEX4aY/PQ1HN9PLHamsiKk04kvrFcV0bIT3OI1IFUp9rlHSqxq+zhaF5mxOC 6Fiyy240vp4NLVowTP4MLfieoXzDobT94a8kSpp5nGrwnH36CZRG8w/+a/xptNf8JcG9 mKg8kebP5rAiwH5mf4VgmNObDn6eVoQK4DzhncpKYuhl9VT4hD1ARA89rkPbRdpJ9BIZ slN2G4kAWM1WVG6evEwGNB4LuicWuyAZb/eb7EJsx8tX0AS6sr0QqYa+oT79mk6z5QC+ 0HFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1780696761; x=1781301561; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=zc/n8iXQaUil2qy8JG0M/lXfN7O6sI37sHV4EIazQEc=; b=Mo5Tdp1PHF5vq3vttNugWLnegddzKeQnwuSzVAgH9Yyczo0p6q6cxWkfqm3HBfsQmI xlwIIGmr+j5px8bfuH5DroBUSHUL6/mPNQNXg5DAp3URGW5PVGVpjtrXNTqbMSky1tj1 1YmZC8LguExgTpA+ZpYjwTUYDc30zGND32WV3ye8ei3zXaNTE7T1Epq9OZTPqenkmmXN VJEIDhkZ3I21HGY/CAhXy6yLjBN6kMU+Gni4C4b/BS/+2bj1xUeHz+6w7d0r+FTauxDY N8/CngAY4KPj2KgV5HUNLsih0542aSeVqXoHV2weQGwOJZS8S5gKzsPxXu8X9ppgnpFe fYLg== X-Forwarded-Encrypted: i=1; AFNElJ+C6CYqaqngOwH/xpmJKbhjUlLHLmVF13madnEQexXC4TW3WHZJt9vQjQdS88hQ6kTOoBpYxseeNUnoFM5g@lists.postgresql.org X-Gm-Message-State: AOJu0YyjjqVhsqFt05scouzAjjc9iyPvpUBGHohIV68EnbOHoqArh0v/ OCzNCDMB0qsroNtOKv4YjCAamplZIHh2HaPHQW9vm64FM4+Wm7aqCnRZy4WYeAjiTsU= X-Gm-Gg: Acq92OGmIf1knDS5VPP9yT1fEsjRJji/4jQGzFmL1D2O5pZ8TYw92pEUo41FHS1o8a2 eI6ycyJwLYt4OesudFaoCbmBlglneSNRv/0K8Z241Zb92zRA03fAXz1pG3NZdvoUX2Zj7BCv0Kl mes1tgZd7KrTyj5BLAD1V0L9RK7Wv+kg1lNDAJsPekkvVfLDZacMtJr1o6Pf7ILpKq5sVt7CKBl Y9gyxgmXGGtV592C8wW4OFxMIBXNhWc0WPPHXMBFBMjA116/C929U9dzfxVixfsjFd3ALa2g28w 8a2hm4QUJNa+XoAW/vAELmVWTVuhhUJbWU6l7xxAf9KMU0iwy4qBX2qw5I8f8h2VjJq5+VxzgxY X5M+0D6SVceyl9PkkcsTUs0tMFDxi2oQxP1lvma0gr88Ju2RotIzwhbM6JRzW3jCagfQiYQ49Wc fAN6BpbA93MdP6m8xaU5yHOOwOWFUJFlDDHiYuCAlASOSutY/FOV/qGCAsxsDnCaxImFzuGXofR RI= X-Received: by 2002:a05:600c:34cb:b0:48e:6db3:ff3a with SMTP id 5b1f17b1804b1-490c25b09a2mr95599655e9.16.1780696760938; Fri, 05 Jun 2026 14:59:20 -0700 (PDT) Received: from laurenz.albe-K4N0CV00F97414D ([2001:871:270:21f:fc97:3ffd:7f89:d662]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-490bc413adbsm185257855e9.15.2026.06.05.14.59.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Jun 2026 14:59:20 -0700 (PDT) Message-ID: <71e9dfb092c0b78a4e6860c7fadfd9d47f55fa32.camel@cybertec.at> Subject: Re: Postgres 12 update to new major version From: Laurenz Albe To: Boris =?UTF-8?Q?Dov=C4=8D=C3=ADk?= , pgsql-general@lists.postgresql.org Date: Fri, 05 Jun 2026 23:59:20 +0200 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.58.3 (3.58.3-1.fc43) MIME-Version: 1.0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Fri, 2026-06-05 at 14:11 +0200, Boris Dov=C4=8D=C3=ADk wrote: > I have a question regarding the update of the production database (multip= le TB of data) > from version 12 to higher major version. We would like to jump to 15 or 1= 6. DB is installed > on a Linux server with one replica on another, it is not on cloud. >=20 > First question is should we perform=C2=A0updates one by one? 12 -> 13 -> = 14 etc. or is it > viable=C2=A0to jump to 16 right away? (We have few functions but usually = its plain tables) You can jump over versions, but you should not upgrade to an old release li= ke v15 or v16. Go to v18 or better. It looks like you are not too eager to upgrade = frequently, otherwise you would not be on v12 today. So I recommend that you put the t= ime when the next upgrade will be necessary as far into the future as possible. > Second we are contemplating=C2=A0options for the update since we are limi= ted with downtime. > We could get 4 hours of downtime for the whole update (either via pg_upda= te or dumps). > We are not sure how to estimate the time for direct update or dumps. What= would be the > recommended way for it? You should use pg_upgrade --link. Then the upgrade can be a matter of minu= tes, unless you have lots and lots of tables, functions or large objects. Yours, Laurenz Albe