pg_controldata (1)
那么和xlog相关的还有个查看数据库状态的命令:pg_controldata, 执行结果如下图:源文件:https://github.com/linwanggm/postxc/blob/master/pg_controldata_modify.c[wln@localhost data]$ pg_controldatapg_control version number:
·
那么和xlog相关的还有个查看数据库状态的命令:pg_controldata, 执行结果如下图:
源文件:https://github.com/linwanggm/postxc/blob/master/pg_controldata_modify.c
[wln@localhost data]$ pg_controldata
pg_control version number: 937
Catalog version number: 201306121
Database system identifier: 6087136306838363069
Database cluster state: in production
pg_control last modified: 2014年11月30日 星期日 10时17分26秒
Latest checkpoint location: 3/1000058
Prior checkpoint location: 3/58
Latest checkpoint's REDO location: 3/1000024
Latest checkpoint's REDO WAL file: 000000010000000300000001
Latest checkpoint's TimeLineID: 1
Latest checkpoint's PrevTimeLineID: 1
Latest checkpoint's full_page_writes: on
Latest checkpoint's NextXID: 0/1858
Latest checkpoint's NextOID: 16450
Latest checkpoint's NextMultiXactId: 1
Latest checkpoint's NextMultiOffset: 0
Latest checkpoint's oldestXID: 1768
Latest checkpoint's oldestXID's DB: 1
Latest checkpoint's oldestActiveXID: 1858
Latest checkpoint's oldestMultiXid: 1
Latest checkpoint's oldestMulti's DB: 1
Time of latest checkpoint: 2014年11月30日 星期日 10时17分24秒
Fake LSN counter for unlogged rels: 0/1
Minimum recovery ending location: 0/0
Min recovery ending loc's timeline: 0
Backup start location: 0/0
Backup end location: 0/0
End-of-backup record required: no
Current wal_level setting: hot_standby
Current max_connections setting: 100
Current max_prepared_xacts setting: 0
Current max_locks_per_xact setting: 64
Maximum data alignment: 4
Database block size: 8192
Blocks per segment of large relation: 131072
WAL block size: 8192
Bytes per WAL segment: 16777216
Maximum length of identifiers: 64
Maximum columns in an index: 32
Maximum size of a TOAST chunk: 2000
Date/time type storage: 64-bit integers
Float4 argument passing: by value
Float8 argument passing: by reference
Data page checksum version: 0
这里整理了源码文件(r1.c):
执行结果:
[wln@localhost data]$ ./r1
-------256
pg_control version number: 937
Database cluster state: in production
Database cluster state: in production
Latest checkpoint location: 3/10000EC
Prior checkpoint location: 3/1000058
Latest checkpoint's REDO location: 3/10000B8
Latest checkpoint's REDO WAL file: 000000010000000300000001
Latest checkpoint's TimeLineID: 1
Latest checkpoint's PrevTimeLineID: 1
Latest checkpoint's full_page_writes: on
Latest checkpoint's NextXID: 0/1858
Latest checkpoint's NextOID: 16450
Latest checkpoint's NextMultiXactId: 1
Latest checkpoint's NextMultiOffset: 0
Latest checkpoint's oldestXID: 1768
Latest checkpoint's oldestXID's DB: 1
Latest checkpoint's oldestActiveXID: 1858
Latest checkpoint's oldestMultiXid: 1
Latest checkpoint's oldestMulti's DB: 1
Fake LSN counter for unlogged rels: 0/1
Minimum recovery ending location: 0/0
Min recovery ending loc's timeline: 0
Backup start location: 0/0
Backup end location: 0/0
End-of-backup record required: no
Current wal_level setting: hot_standby
Current wal_log_hints setting: on
Current max_connections setting: 0
Current max_worker_processes setting: 64
Current max_prepared_xacts setting: 4
Current max_locks_per_xact setting: 0
Maximum data alignment: 1093850759
Database block size: 8192
Blocks per segment of large relation: 16777216
WAL block size: 64
Bytes per WAL segment: 32
Maximum length of identifiers: 2000
Maximum columns in an index: 257
Maximum size of a TOAST chunk: 0
Size of a large-object chunk: 737221047
Date/time type storage: floating-point numbers
Float4 argument passing: by reference
Float8 argument passing: by reference
Data page checksum version: 0
有关xlog的内容请参考文档(postgres xlog):http://blog.sina.com.cn/s/blog_67d069a90101qv54.html
源文件:https://github.com/linwanggm/postxc/blob/master/pg_controldata_modify.c
[wln@localhost data]$ pg_controldata
pg_control version number: 937
Catalog version number: 201306121
Database system identifier: 6087136306838363069
Database cluster state: in production
pg_control last modified: 2014年11月30日 星期日 10时17分26秒
Latest checkpoint location: 3/1000058
Prior checkpoint location: 3/58
Latest checkpoint's REDO location: 3/1000024
Latest checkpoint's REDO WAL file: 000000010000000300000001
Latest checkpoint's TimeLineID: 1
Latest checkpoint's PrevTimeLineID: 1
Latest checkpoint's full_page_writes: on
Latest checkpoint's NextXID: 0/1858
Latest checkpoint's NextOID: 16450
Latest checkpoint's NextMultiXactId: 1
Latest checkpoint's NextMultiOffset: 0
Latest checkpoint's oldestXID: 1768
Latest checkpoint's oldestXID's DB: 1
Latest checkpoint's oldestActiveXID: 1858
Latest checkpoint's oldestMultiXid: 1
Latest checkpoint's oldestMulti's DB: 1
Time of latest checkpoint: 2014年11月30日 星期日 10时17分24秒
Fake LSN counter for unlogged rels: 0/1
Minimum recovery ending location: 0/0
Min recovery ending loc's timeline: 0
Backup start location: 0/0
Backup end location: 0/0
End-of-backup record required: no
Current wal_level setting: hot_standby
Current max_connections setting: 100
Current max_prepared_xacts setting: 0
Current max_locks_per_xact setting: 64
Maximum data alignment: 4
Database block size: 8192
Blocks per segment of large relation: 131072
WAL block size: 8192
Bytes per WAL segment: 16777216
Maximum length of identifiers: 64
Maximum columns in an index: 32
Maximum size of a TOAST chunk: 2000
Date/time type storage: 64-bit integers
Float4 argument passing: by value
Float8 argument passing: by reference
Data page checksum version: 0
这里整理了源码文件(r1.c):
执行结果:
[wln@localhost data]$ ./r1
-------256
pg_control version number: 937
Database cluster state: in production
Database cluster state: in production
Latest checkpoint location: 3/10000EC
Prior checkpoint location: 3/1000058
Latest checkpoint's REDO location: 3/10000B8
Latest checkpoint's REDO WAL file: 000000010000000300000001
Latest checkpoint's TimeLineID: 1
Latest checkpoint's PrevTimeLineID: 1
Latest checkpoint's full_page_writes: on
Latest checkpoint's NextXID: 0/1858
Latest checkpoint's NextOID: 16450
Latest checkpoint's NextMultiXactId: 1
Latest checkpoint's NextMultiOffset: 0
Latest checkpoint's oldestXID: 1768
Latest checkpoint's oldestXID's DB: 1
Latest checkpoint's oldestActiveXID: 1858
Latest checkpoint's oldestMultiXid: 1
Latest checkpoint's oldestMulti's DB: 1
Fake LSN counter for unlogged rels: 0/1
Minimum recovery ending location: 0/0
Min recovery ending loc's timeline: 0
Backup start location: 0/0
Backup end location: 0/0
End-of-backup record required: no
Current wal_level setting: hot_standby
Current wal_log_hints setting: on
Current max_connections setting: 0
Current max_worker_processes setting: 64
Current max_prepared_xacts setting: 4
Current max_locks_per_xact setting: 0
Maximum data alignment: 1093850759
Database block size: 8192
Blocks per segment of large relation: 16777216
WAL block size: 64
Bytes per WAL segment: 32
Maximum length of identifiers: 2000
Maximum columns in an index: 257
Maximum size of a TOAST chunk: 0
Size of a large-object chunk: 737221047
Date/time type storage: floating-point numbers
Float4 argument passing: by reference
Float8 argument passing: by reference
Data page checksum version: 0
有关xlog的内容请参考文档(postgres xlog):http://blog.sina.com.cn/s/blog_67d069a90101qv54.html
更多推荐
所有评论(0)