| From: | Richard Yen <richyen3(at)gmail(dot)com> |
|---|---|
| To: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
| Cc: | myon(at)debian(dot)org |
| Subject: | Patch to allow pg_filedump to support reading of pg_filenode.map |
| Date: | 2021-04-29 00:54:22 |
| Message-ID: | CAKH4vDiJAu0Sx+aD4i2pV4ALJrEF7kySoCEHgJ_butK+Ldnt1Q@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Hello Hackers,
I recently had to work on a case where some catalog files were
corrupt and/or missing. One of the things we sought to inspect was
pg_filenode.map, but there was no tooling available to do so.
With the help of Álvaro H.. I've put together a patch to allow pg_filedump
to do some rudimentary decoding of pg_filenode.map, so that it's at least
human-readable. I had the idea to try to map the OIDs to relnames, but
that might get hairy, with TOAST table OIDs possibly changing (for pg_proc,
etc.)
It seems that Christoph Berg is the primary committer for the pg_filedump
project these days so he is cc'd here, but if there's some other place I
should be sending this kind of contribution to, please let me know.
Hopefully this will be helpful to others in the future.
Much appreciated,
--Richard
| Attachment | Content-Type | Size |
|---|---|---|
| add_filenode_support.patch | application/octet-stream | 3.9 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andres Freund | 2021-04-29 00:59:22 | Re: WIP: WAL prefetch (another approach) |
| Previous Message | Yura Sokolov | 2021-04-29 00:30:47 | Re: Use simplehash.h instead of dynahash in SMgr |