pg.ddx.io pgsql-general@postgresql.org mailing list archive
help / color / mirror / Atom feedRestoring 9.1 db from crashed disk/VM
2+ messages / 2 participants
[nested] [flat]
* Restoring 9.1 db from crashed disk/VM
@ 2021-01-02 11:49 robert <robert@redcor.ch>
2021-01-02 11:54 ` Re: Restoring 9.1 db from crashed disk/VM Magnus Hagander <magnus@hagander.net>
0 siblings, 1 reply; 2+ messages in thread
From: robert @ 2021-01-02 11:49 UTC (permalink / raw)
To: pgsql-general
Friends
I hope you had a good start into 2021.
I would like to get some advice on how to restore a 9.1 DB, of which I have the
/var/lib/postgresql
with some 20GB salvaged.
Now I find now easily usable 9.1 PostgreSQL installer anymore.
How should I proceed to get that data in a newer PG loaded?
Could I just install a 9.5 and copy the salvaged folder into
/var/lib/postgresql/9/main
Or could I add the folder to my PG 12 installation like:
/var/lib/postgresql/12/main
/9/main
and tell PG 12 somehow to read the data for the PG9 folder?
Thanks for your insights
Robert
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: Restoring 9.1 db from crashed disk/VM
2021-01-02 11:49 Restoring 9.1 db from crashed disk/VM robert <robert@redcor.ch>
@ 2021-01-02 11:54 ` Magnus Hagander <magnus@hagander.net>
0 siblings, 0 replies; 2+ messages in thread
From: Magnus Hagander @ 2021-01-02 11:54 UTC (permalink / raw)
To: robert <robert@redcor.ch>; +Cc: pgsql-general
On Sat, Jan 2, 2021 at 12:50 PM robert <robert@redcor.ch> wrote:
>
> Friends
>
> I hope you had a good start into 2021.
>
>
> I would like to get some advice on how to restore a 9.1 DB, of which I have the
>
> /var/lib/postgresql
>
> with some 20GB salvaged.
>
> Now I find now easily usable 9.1 PostgreSQL installer anymore.
>
> How should I proceed to get that data in a newer PG loaded?
>
> Could I just install a 9.5 and copy the salvaged folder into
>
> /var/lib/postgresql/9/main
>
>
> Or could I add the folder to my PG 12 installation like:
>
> /var/lib/postgresql/12/main
> /9/main
>
> and tell PG 12 somehow to read the data for the PG9 folder?
No, you need a PostgreSQL of the same version that you had for the
backups, in this case 9.1. No version outside of 9.1 will be able to
directly use that data folder.
You don't mention what your operating system is, but baked on the
paths you mention it sounds like a debian based system. If that is it,
then the apt-archive will contain binaries (unsupported of course) for
these old versions. See https://apt-archive.postgresql.org/
If not, then you will have to build from source manually -- the old
versions of PostgreSQL are still available in source form on
https://ftp.postgresql.org/pub/source/
--
Magnus Hagander
Me: https://www.hagander.net/
Work: https://www.redpill-linpro.com/
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2021-01-02 11:54 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-01-02 11:49 Restoring 9.1 db from crashed disk/VM robert <robert@redcor.ch>
2021-01-02 11:54 ` Magnus Hagander <magnus@hagander.net>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox