|
|
|
|
@ -300,7 +300,7 @@ XLogDumpXLogRead(const char *directory, TimeLineID timeline_id, |
|
|
|
|
|
|
|
|
|
XLogFileName(fname, timeline_id, sendSegNo); |
|
|
|
|
|
|
|
|
|
fatal_error("could not seek in log segment %s to offset %u: %s", |
|
|
|
|
fatal_error("could not seek in log file %s to offset %u: %s", |
|
|
|
|
fname, startoff, strerror(err)); |
|
|
|
|
} |
|
|
|
|
sendOff = startoff; |
|
|
|
|
@ -320,7 +320,7 @@ XLogDumpXLogRead(const char *directory, TimeLineID timeline_id, |
|
|
|
|
|
|
|
|
|
XLogFileName(fname, timeline_id, sendSegNo); |
|
|
|
|
|
|
|
|
|
fatal_error("could not read from log segment %s, offset %d, length %d: %s", |
|
|
|
|
fatal_error("could not read from log file %s, offset %u, length %d: %s", |
|
|
|
|
fname, sendOff, segbytes, strerror(err)); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -710,14 +710,14 @@ usage(void) |
|
|
|
|
printf(_(" -n, --limit=N number of records to display\n")); |
|
|
|
|
printf(_(" -p, --path=PATH directory in which to find log segment files or a\n" |
|
|
|
|
" directory with a ./pg_wal that contains such files\n" |
|
|
|
|
" (default: current directory, ./pg_wal, PGDATA/pg_wal)\n")); |
|
|
|
|
printf(_(" -r, --rmgr=RMGR only show records generated by resource manager RMGR\n" |
|
|
|
|
" (default: current directory, ./pg_wal, $PGDATA/pg_wal)\n")); |
|
|
|
|
printf(_(" -r, --rmgr=RMGR only show records generated by resource manager RMGR;\n" |
|
|
|
|
" use --rmgr=list to list valid resource manager names\n")); |
|
|
|
|
printf(_(" -s, --start=RECPTR start reading at WAL location RECPTR\n")); |
|
|
|
|
printf(_(" -t, --timeline=TLI timeline from which to read log records\n" |
|
|
|
|
" (default: 1 or the value used in STARTSEG)\n")); |
|
|
|
|
printf(_(" -V, --version output version information, then exit\n")); |
|
|
|
|
printf(_(" -x, --xid=XID only show records with TransactionId XID\n")); |
|
|
|
|
printf(_(" -x, --xid=XID only show records with transaction ID XID\n")); |
|
|
|
|
printf(_(" -z, --stats[=record] show statistics instead of records\n" |
|
|
|
|
" (optionally, show per-record statistics)\n")); |
|
|
|
|
printf(_(" -?, --help show this help, then exit\n")); |
|
|
|
|
@ -870,7 +870,7 @@ main(int argc, char **argv) |
|
|
|
|
case 'x': |
|
|
|
|
if (sscanf(optarg, "%u", &config.filter_by_xid) != 1) |
|
|
|
|
{ |
|
|
|
|
fprintf(stderr, _("%s: could not parse \"%s\" as a valid xid\n"), |
|
|
|
|
fprintf(stderr, _("%s: could not parse \"%s\" as a transaction ID\n"), |
|
|
|
|
progname, optarg); |
|
|
|
|
goto bad_argument; |
|
|
|
|
} |
|
|
|
|
@ -910,7 +910,7 @@ main(int argc, char **argv) |
|
|
|
|
if (!verify_directory(private.inpath)) |
|
|
|
|
{ |
|
|
|
|
fprintf(stderr, |
|
|
|
|
_("%s: path \"%s\" cannot be opened: %s\n"), |
|
|
|
|
_("%s: path \"%s\" could not be opened: %s\n"), |
|
|
|
|
progname, private.inpath, strerror(errno)); |
|
|
|
|
goto bad_argument; |
|
|
|
|
} |
|
|
|
|
@ -931,7 +931,7 @@ main(int argc, char **argv) |
|
|
|
|
private.inpath = directory; |
|
|
|
|
|
|
|
|
|
if (!verify_directory(private.inpath)) |
|
|
|
|
fatal_error("cannot open directory \"%s\": %s", |
|
|
|
|
fatal_error("could not open directory \"%s\": %s", |
|
|
|
|
private.inpath, strerror(errno)); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -1029,7 +1029,9 @@ main(int argc, char **argv) |
|
|
|
|
* a segment (e.g. we were used in file mode). |
|
|
|
|
*/ |
|
|
|
|
if (first_record != private.startptr && (private.startptr % XLogSegSize) != 0) |
|
|
|
|
printf(_("first record is after %X/%X, at %X/%X, skipping over %u bytes\n"), |
|
|
|
|
printf(ngettext("first record is after %X/%X, at %X/%X, skipping over %u byte\n", |
|
|
|
|
"first record is after %X/%X, at %X/%X, skipping over %u bytes\n", |
|
|
|
|
(first_record - private.startptr)), |
|
|
|
|
(uint32) (private.startptr >> 32), (uint32) private.startptr, |
|
|
|
|
(uint32) (first_record >> 32), (uint32) first_record, |
|
|
|
|
(uint32) (first_record - private.startptr)); |
|
|
|
|
|