al <al@xxxxxxxxxxx> writes: > Hello. I'm trying to restore/rescue a database from some that I have: > * I have all the recent files in PGDATA/base > (/var/lib/postgresql/9.6/main/base/), but I have not the complete > /var/lib/postgresql/9.6/main/ > * I have all files from an old backup (and not much different) dump > that I restored in a new installation of PostgreSQL-9.6. > * I have a lot of rescued files from the hard drive (from ddrescue) > and I got thousand of files without a name (having a "#" and then a > number instead and in lost+found directory), so, for instance: > * I have the pg_class file > * I have the pg_clog directory with 0000 file > I have not: > * I have not the original content in pg_xlog directory (I have an > old one, maybe, if it didn't changed, it still being useful) Unfortunately, not having an up-to-date copy of the xlog info is practically fatal to your hopes of getting back consistent data. There are some Postgres support companies who specialize in data recovery; if this data is worth money to you, go hire a specialist. The chance of hacking your way to a usable fix without knowing exactly what you're doing is nil. (A specialist might not be successful either, of course.) regards, tom lane