-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathREADME.xlogdump
109 lines (83 loc) · 3.66 KB
/
README.xlogdump
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
xlogdump README
What's `xlogdump'?
==================
A tool for extracting data from the PostgreSQL's write ahead logs.
How to install
==============
To build xlogdump, you don't need to have PostgreSQL source tree.
You can build xlogdump with using pgxs, PostgreSQL header files
and shared libraries.
If you're using PostgreSQL from some RPM packages, those additional
requirements are generally included in the supplemental devel package.
You need to install it before building xlogdump.
Also, make sure that you're going to build xlogdump against the same
architecture (i686 or x86_64) and the same major version of PostgreSQL.
Currently, xlogdump cannot deal with WAL files generated on the different
architecture. So, you need to build xlogdump on the 32-bit architecture
when you want to analyze WAL files generated on the 32-bit box.
64-bit as well.
You need to set two environmental variables, PATH and USE_PGXS.
And then, run `make' and `make install' at the directory where
you extracted xlogdump source code.
export PATH=$PATH:/usr/local/pgsql/bin
export USE_PGXS=1
make
make install
Supported Version
=================
xlogdump is able to be compiled and work with following versions:
- PostgreSQL 9.2.x
- PostgreSQL 9.1.x
- PostgreSQL 9.0.x
- PostgreSQL 8.4.x
- PostgreSQL 8.3.x
Usage
=====
Usage:
xlogdump [OPTION]... [segment file(s)]
Options:
-r, --rmid=RMID Outputs only the transaction log records
containing the specified operation.
RMID:Resource Manager
0:XLOG
1:Transaction
2:Storage
3:CLOG
4:Database
5:Tablespace
6:MultiXact
7:RelMap
8:Standby
9:Heap2
10:Heap
11:Btree
12:Hash
13:Gin
14:Gist
15:Sequence
16:SPGist
-x, --xid=XID Outputs only the transaction log records
containing the specified transaction id.
-t, --transactions Outputs only transaction info: the xid,
total length and status of each transaction.
-s, --statements Tries to build fake statements that produce the
physical changes found within the xlog segments.
-S, --stats Collects and shows statistics of the transaction
log records from the xlog segments.
-n, --oid2name Show object names instead of OIDs with looking up
the system catalogs or a cache file.
-g, --gen_oid2name Generate an oid2name cache file (oid2name.out)
by reading the system catalogs.
-T, --hide-timestamps Do not print timestamps.
-?, --help Show this help.
oid2name supplimental options:
-h, --host=HOST database server host or socket directory
-p, --port=PORT database server port number
-U, --user=NAME database user name to connect
-d, --dbname=NAME database name to connect
-f, --file=FILE file name to read oid2name cache
Bug report
==========
Any bug reports and/or comments are welcome. Please send them to the
author:
Satoshi Nagayasu <[email protected]>