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 1rO2ex-000jhg-5N for pgsql-admin@arkaria.postgresql.org; Thu, 11 Jan 2024 21:32:19 +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 1rO2eu-00FFyu-M5 for pgsql-admin@arkaria.postgresql.org; Thu, 11 Jan 2024 21:32:16 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rO2eu-00FFym-6d for pgsql-admin@lists.postgresql.org; Thu, 11 Jan 2024 21:32:16 +0000 Received: from mail-yb1-xb33.google.com ([2607:f8b0:4864:20::b33]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rO2er-0014xl-12 for pgsql-admin@lists.postgresql.org; Thu, 11 Jan 2024 21:32:14 +0000 Received: by mail-yb1-xb33.google.com with SMTP id 3f1490d57ef6-dbed729a51eso4936015276.0 for ; Thu, 11 Jan 2024 13:32:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1705008730; x=1705613530; darn=lists.postgresql.org; h=to:in-reply-to:cc:references:message-id:date:subject:mime-version :from:content-transfer-encoding:from:to:cc:subject:date:message-id :reply-to; bh=6GPq7WxM0Ty+2Bbncc1/HmW/L4JcrzRH7e7WyuWpX2U=; b=S2taNVdeXwbUiVAvh9xK05Hp0MFJkEJUfCdoJfR1xC7anzRyppw1cia6NH6F0sJZ17 eO1W5h2ZyQqvIWFm0Osmx0IxubjNNeTNQgaylTlIUng5PjdkYRCw+jWJxyfEUrsdDWwq HXP8UU+wD46/xAW+xd5t0xa0WSwX2QGbdI1QbygX4offIhYjnjy07bPDsyDmXW6c3wev nownzwLUPtauSsngx/i6+PJC7Gmo7iDExTFhvbSqoC/B/g4K2QY1sLTXhdivAaDkc/OQ pfcoxK5nSCfVgybSWJttHO9ipObn2ZV219nYsuyGH2K0R/G4oTWOtkjWj4gYXkEqMZox z6Hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705008730; x=1705613530; h=to:in-reply-to:cc:references:message-id:date:subject:mime-version :from:content-transfer-encoding:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=6GPq7WxM0Ty+2Bbncc1/HmW/L4JcrzRH7e7WyuWpX2U=; b=lusfJ9oCsIspz0Lcbjf3t51xJAj47RiK7laDHTBrxThIxHpYmEkZ4eur1JQWkwF9Un krt4ohcIjb/d4kKZa39gDXgkWDkdM92oH5gO+Rgb47JU5DwLpTfRIKNXzN3RrfGY1tKj q2Rs1FMSi+RImKqi+6RRPnSbaPIlRAv1OPN4rz1NborBUPwu/r5y69Up5N/WuApJG93b REI4a6Yr9iOvIodvBPEQQjjT3dsCt6wKcFYU9cnqml8dMCDts1c/Z1uDFfySu4hNKA96 fLgVVycylw4tj5Hnv+GlX8svwFzLUmaAowEfVW0H8k2L5ZaEDWaM0X9ZosqRAZ0+IXUY IL6Q== X-Gm-Message-State: AOJu0Yz6d9Bg76NaXnjrbMoLtrufjqx1MCRcgrmruRlYCQM9qC+EzRAy Xb94/g81bm2e2w9PBchvsizT46i0EuI= X-Google-Smtp-Source: AGHT+IFIoEdr+OYlgE3S7us3I9hKsq90eIR2Jf7ScRm8HpOExOCsuq1snKIGQA2sRNal51idoHhLkA== X-Received: by 2002:a5b:94a:0:b0:dbd:120e:f337 with SMTP id x10-20020a5b094a000000b00dbd120ef337mr281422ybq.30.1705008730406; Thu, 11 Jan 2024 13:32:10 -0800 (PST) Received: from smtpclient.apple ([2600:100b:b125:ca03:6c13:c047:d4cc:1871]) by smtp.gmail.com with ESMTPSA id z5-20020a25ad85000000b00dbd22f14840sm682443ybi.13.2024.01.11.13.32.09 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 11 Jan 2024 13:32:10 -0800 (PST) Content-Type: multipart/alternative; boundary=Apple-Mail-6535AB43-4703-40AE-B1D4-B3B391EF3B95 Content-Transfer-Encoding: 7bit From: Andrew Wang Mime-Version: 1.0 (1.0) Subject: Re: Test mail for pgsql-admin Date: Thu, 11 Jan 2024 15:31:58 -0600 Message-Id: <531DC65B-1ED0-4A65-887E-C4F548C089C8@gmail.com> References: <983811fd-e0ad-5606-ce9e-3110f73feaec@jakobs.com> Cc: pgsql-admin@lists.postgresql.org In-Reply-To: <983811fd-e0ad-5606-ce9e-3110f73feaec@jakobs.com> To: Holger Jakobs X-Mailer: iPhone Mail (21B101) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --Apple-Mail-6535AB43-4703-40AE-B1D4-B3B391EF3B95 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable Okay thanks 
Best,


<= div dir=3D"ltr">
On Jan 11, 2024, at 3:26=E2=80= =AFPM, Holger Jakobs <holger@jakobs.com> wrote:

=EF=BB=BF =20 =20 =20

Unless you read all of the PostgreSQL source code and mimic its behaviour, I regard this impossible. Those files from the DATA directory aren't simple CSV files or similar.


Am 11.01.24 um 22:24 schrieb Andrew Wang:
These files were backed up to another Linux system. Is it possible to convert it into a program readable format? I can write a script in most languages to read them.
Best,



On Jan 11, 2024, at 3:18=E2=80=AFPM, Holge= r Jakobs <holger@jakobs.com> wrote:

=EF=BB=BF

You can always dump the contents of a running instance (called cluster) using pg_dumpall creating a text file with SQL commands, which can be fed subsequently into any empty, but running installation of the same or more recent version of the server using psql.

What isn't possible is getting a corrupted copy of the data directory back to life.

Unless you took the copy while the database server was completely down, regard it unusable.

If the copy isn't corrupt, you can start it on the same architecture with the same major version of the software again using pg_ctl. Look at the help of the program for details.

When the database system is running again, take a dump with pg_dumpall.

Am 11.01.24 um 22:12 schrieb Andrew Wang:
They were separated. The source list in Ubuntu 18 was moved because the 16 is different from former versions, which caused the problem, as I upgraded the Linux system before, it worked very well.

I tried to install the 15 and 16, but the configuration complained ports and other things. Any way to dump all into a format from another computer and then read them into the new 16?
Best,



On Jan 11, 2024, at 2:28=E2=80=AFP= M, Ron Johnson <ronljohnsonjr@gmail.co= m> wrote:

=EF=BB=BF
"I assumed they can merged into 16 but they were not after upgrading my system."

Yeah... that's a pretty unfounded assumption.
=

Fortunately, your data might be salvageable, if the new system has separate -- an= d populated -- directories for 12, 13 and 14.  Were= any of the source system Postgresql instances running when you ran rsync?

If not, then you can install the old versions of Postgresql in parallel with 16, and then run pg_upgrade.

On Thu, Jan 11, 2024 at 3:11=E2=80=AFPM Andrew Wang <andrew.wang.2009@gmail.com> wrote:
I used =E2=80=9Crsync=E2=80=9D in L= inux to backup the the entire directory that contained data for 12,13 and 15. The last 15 was gone after upgrading to 16 with Ubuntu 22.04. I assumed they can merged into 16 but they were not after upgrading my system.
Best,



On Jan 11, 2024, at 1:46=E2=80=AFPM, Rajesh Kumar <rajeshkumar.dba09@gmail.com> wrote:

=EF=BB=BF
Did you take basebackup?&nbs= p;

On Fri, 12 Jan 2024, 00:55 Ron Johnson, <ronljohnsonjr@gmail.com> wrote:
1. What is the source of the data that you copied to /= var/lib/pgsql/15/main?
2. What errors or problems are you having?

= On Thu, Jan 11, 2024 at 12:43=E2=80=AFP= M Andrew Wang <andrew.wang.2009@gmail.com&g= t; wrote:
Dear staff at pqsql,
 I try to restor= e all data from /var/lib/pgsql/15/main, but do not know how and have not found hits from your web as detailed below. Could you provide a tip for that?Thanks. Regards
Your search for resto= re data from /var/lib/pgsql/ returned no hits.

Andrew

On Thu, Jan 11, 2024 at 11:35=E2=80=AFAM= pgsql-admin Owner <pgsql-admi= n-owner@lists.postgresql.org> wrote:
Hello!

This is a test mail for the list

pgsql-admin@lists.postgresql.org
as requested. The mail has the same list-id header
as email delivered to the list, and can be used to
for example test local mail filters.


--
Best,

Andrew Wang
--=20
Holger Jakobs, Bergisch Gladbach, Tel. +49-178-9759012
--=20
Holger Jakobs, Bergisch Gladbach, Tel. +49-178-9759012
=20
= --Apple-Mail-6535AB43-4703-40AE-B1D4-B3B391EF3B95--