TBase集群安装配置

什么是TBase(来自https://www.bookstack.cn/read/TBase/196700

TBase是一个提供写可靠性,多主节点数据同步的关系数据库集群平台。你可以将TBase配置一台或者多台主机上,TBase数据存储在多台物理主机上面。数据表的存储有两种方式, 分别是distributed或者replicated ,当向TBase发送查询 SQL时,TBase会自动向数据节点发出查询语句并获取最终结果。

TBase采用分布式集群架构(如下图), 该架构分布式为无共享(share nothing)模式,节点之间相应独立,各自处理自己的数据,处理后的结果可能向上层汇总或在节点间流转,各处理单元之间通过网络协议进行通信,并行处理和扩展能力更好,这也意味着只需要简单的x86服务器就可以部署TBase数据库集群

TBase的三大模块

  • Coordinator:协调节点(简称CN)

业务访问入口,负责数据的分发和查询规划,多个节点位置对等,每个节点都提供相同的数据库视图;在功能上CN上只存储系统的全局元数据,并不存储实际的业务数据。

  • Datanode:数据节点(简称DN)

每个节点还存储业务数据的分片在功能上,DN节点负责完成执行协调节点分发的执行请求。

  • GTM:全局事务管理器(Global Transaction Manager)

负责管理集群事务信息,同时管理集群的全局对象,比如序列等。

 

TBase集群环境的搭建。

安装环境:centos 7.4 
内存:6g(至少4g)
参考文章:https://github.com/Tencent/TBase/wiki/1%E3%80%81TBase_Quick_Start

提前配置事项
防火墙与selinux配置
关闭seLinux:setenforce 0
设置selinu开机不启动:
vi /etc/sysconfig/selinux 
将其中的SELINUX= XXXXXX修改为SELINUX=disabled
关闭防火墙:systemctl stop firewalld
禁止防火墙开机自启:systemctl disable firewalld

1.源码获取

git clone https://github.com/Tencent/TBase


2.创建目录和用户

#集群所有机器都需要配置
mkdir /data
mkdir -p /data/tbase/data/gtm
mkdir -p /data/tbase/data/coord
mkdir -p /data/tbase/data/dn001
mkdir -p /data/tbase/data/dn002
mkdir -p /data/tbase/TBase-master
mkdir -p /data/tbase/install

useradd -d /data/tbase tbase
#设密码
passwd tbase

3.源码编译

export SOURCECODE_PATH=/data/tbase/TBase-master
export INSTALL_PATH=/data/tbase/install

cd ${SOURCECODE_PATH}
rm -rf ${INSTALL_PATH}/tbase_bin_v2.0
chmod +x configure*
./configure --prefix=${INSTALL_PATH}/tbase_bin_v2.0  --enable-user-switch --with-openssl  --with-ossp-uuid CFLAGS=-g
make clean
make -sj
make install
chmod +x contrib/pgxc_ctl/make_signature
cd contrib
make -sj
make install

4.集群规划

下面以两台服务器上搭建1GTM主,1GTM备,2CN主(CN主之间对等,因此无需备CN),2DN主,2DN备的集群,该集群为具备容灾能力的最小配置
机器1:192.168.199.240
机器2:192.168.199.241

集群规划如下:

节点名称  IP   数据目录
GTM master192.168.199.240/data/tbase/data/gtm
GTM slave192.168.199.241/data/tbase/data/gtm
CN1 192.168.199.240/data/tbase/data/coord
CN2192.168.199.241/data/tbase/data/coord
DN1 master192.168.199.240 /data/tbase/data/dn001
DN1 slave192.168.199.241 /data/tbase/data/dn001
DN2 master192.168.199.240 /data/tbase/data/dn002
DN2 slave192.168.199.241/data/tbase/data/dn002


                    
           
            
          
            

 

 

 

 

 

5.机器互信

# 240
su tbase
ssh-keygen -t rsa
ssh-copy-id -i ~/.ssh/id_rsa.pub tbase@192.168.199.241
# 241
su tbase
ssh-keygen -t rsa
ssh-copy-id -i ~/.ssh/id_rsa.pub tbase@192.168.199.240

6.设置环境变量

#集群所有机器都需要配置
[tbase@node1 ~]$ vim ~/.bashrc
export TBASE_HOME=/data/tbase/install/tbase_bin_v2.0
export PATH=$TBASE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$TBASE_HOME/lib:${LD_LIBRARY_PATH}

7.初始化集群

[tbase@node1 etc]$ mkdir /data/tbase/pgxc_ctl
[tbase@node1 etc]$ cd /data/tbase/pgxc_ctl
[tbase@node1 pgxc_ctl]$ ll
total 0
[tbase@node1 pgxc_ctl]$ vim pgxc_ctl.conf

#!/bin/bash
pgxcInstallDir=/data/tbase/install/tbase_bin_v2.0
pgxcOwner=tbase
defaultDatabase=postgres
pgxcUser=$pgxcOwner
tmpDir=/tmp
localTmpDir=$tmpDir
configBackup=n
configBackupHost=pgxc-linker
configBackupDir=$HOME/pgxc
configBackupFile=pgxc_ctl.bak


#---- GTM ----------
gtmName=gtm
gtmMasterServer=192.168.199.240
gtmMasterPort=50001
gtmMasterDir=/data/tbase/data/gtm
gtmExtraConfig=none
gtmMasterSpecificExtraConfig=none
gtmSlave=y
gtmSlaveServer=192.168.199.241
gtmSlavePort=50001
gtmSlaveDir=/data/tbase/data/gtm
gtmSlaveSpecificExtraConfig=none

#---- Coordinators -------
coordMasterDir=/data/tbase/data/coord
coordArchLogDir=/data/tbase/data/coord_archlog

coordNames=(cn001 cn002 )
coordPorts=(30004 30004 )
poolerPorts=(31110 31110 )
coordPgHbaEntries=(0.0.0.0/0)
coordMasterServers=(192.168.199.240 192.168.199.241)
coordMasterDirs=($coordMasterDir $coordMasterDir)
coordMaxWALsernder=2
coordMaxWALSenders=($coordMaxWALsernder $coordMaxWALsernder )
coordSlave=n
coordSlaveSync=n
coordArchLogDirs=($coordArchLogDir $coordArchLogDir)

coordExtraConfig=coordExtraConfig
cat > $coordExtraConfig <<EOF
#================================================
# Added to all the coordinator postgresql.conf
# Original: $coordExtraConfig

include_if_exists = '/data/tbase/global/global_tbase.conf'

wal_level = replica
wal_keep_segments = 256 
max_wal_senders = 4
archive_mode = on 
archive_timeout = 1800 
archive_command = 'echo 0' 
log_truncate_on_rotation = on 
log_filename = 'postgresql-%M.log' 
log_rotation_age = 4h 
log_rotation_size = 100MB
hot_standby = on 
wal_sender_timeout = 30min 
wal_receiver_timeout = 30min 
shared_buffers = 1024MB 
max_pool_size = 2000
log_statement = 'ddl'
log_destination = 'csvlog'
logging_collector = on
log_directory = 'pg_log'
listen_addresses = '*'
max_connections = 2000

EOF

coordSpecificExtraConfig=(none none)
coordExtraPgHba=coordExtraPgHba
cat > $coordExtraPgHba <<EOF

local   all             all                                     trust
host    all             all             0.0.0.0/0               trust
host    replication     all             0.0.0.0/0               trust
host    all             all             ::1/128                 trust
host    replication     all             ::1/128                 trust


EOF


coordSpecificExtraPgHba=(none none)
coordAdditionalSlaves=n    
cad1_Sync=n

#---- Datanodes ---------------------
dn1MstrDir=/data/tbase/data/dn001
dn2MstrDir=/data/tbase/data/dn002
dn1SlvDir=/data/tbase/data/dn001
dn2SlvDir=/data/tbase/data/dn002
dn1ALDir=/data/tbase/data/datanode_archlog
dn2ALDir=/data/tbase/data/datanode_archlog

primaryDatanode=dn001
datanodeNames=(dn001 dn002)
datanodePorts=(40004 40004)
datanodePoolerPorts=(41110 41110)
datanodePgHbaEntries=(0.0.0.0/0)
datanodeMasterServers=(192.168.199.240 192.168.199.241)
datanodeMasterDirs=($dn1MstrDir $dn2MstrDir)
dnWALSndr=4
datanodeMaxWALSenders=($dnWALSndr $dnWALSndr)

datanodeSlave=y
datanodeSlaveServers=(192.168.199.241 192.168.199.240)
datanodeSlavePorts=(50004 54004)
datanodeSlavePoolerPorts=(51110 51110)
datanodeSlaveSync=n
datanodeSlaveDirs=($dn1SlvDir $dn2SlvDir)
datanodeArchLogDirs=($dn1ALDir/dn001 $dn2ALDir/dn002)

datanodeExtraConfig=datanodeExtraConfig
cat > $datanodeExtraConfig <<EOF
#================================================
# Added to all the coordinator postgresql.conf
# Original: $datanodeExtraConfig

include_if_exists = '/data/tbase/global/global_tbase.conf'
listen_addresses = '*' 
wal_level = replica 
wal_keep_segments = 256 
max_wal_senders = 4
archive_mode = on 
archive_timeout = 1800 
archive_command = 'echo 0' 
log_directory = 'pg_log' 
logging_collector = on 
log_truncate_on_rotation = on 
log_filename = 'postgresql-%M.log' 
log_rotation_age = 4h 
log_rotation_size = 100MB
hot_standby = on 
wal_sender_timeout = 30min 
wal_receiver_timeout = 30min 
shared_buffers = 1024MB 
max_connections = 4000 
max_pool_size = 4000
log_statement = 'ddl'
log_destination = 'csvlog'
wal_buffers = 1GB

EOF

datanodeSpecificExtraConfig=(none none)
datanodeExtraPgHba=datanodeExtraPgHba
cat > $datanodeExtraPgHba <<EOF

local   all             all                                     trust
host    all             all             0.0.0.0/0               trust
host    replication     all             0.0.0.0/0               trust
host    all             all             ::1/128                 trust
host    replication     all             ::1/128                 trust


EOF

datanodeSpecificExtraPgHba=(none none)

datanodeAdditionalSlaves=n
walArchive=n

8.分发二进制包

#在一个节点配置好配置文件后,需要预先将二进制包部署到所有节点所在的机器上,这个可以使用pgxc_ctl工具,执行deploy all命令来完成。
[tbase@node1 etc]$ pgxc_ctl
/bin/bash
Installing pgxc_ctl_bash script as /data/tbase/pgxc_ctl/pgxc_ctl_bash.
Installing pgxc_ctl_bash script as /data/tbase/pgxc_ctl/pgxc_ctl_bash.
Reading configuration using /data/tbase/pgxc_ctl/pgxc_ctl_bash --home /data/tbase/pgxc_ctl --configuration /data/tbase/pgxc_ctl/pgxc_ctl.conf
Finished reading configuration.
   ******** PGXC_CTL START ***************

Current directory: /data/tbase/pgxc_ctl
PGXC deploy all
Deploying Postgres-XL components to all the target servers.
Prepare tarball to deploy ... 
Deploying to the server 192.168.199.240.
Deploying to the server 192.168.199.241.

登录到所有节点,check二进制包是否分发OK
[root@node2 install]# cd tbase_bin_v2.0/
[root@node2 tbase_bin_v2.0]# ll
total 12
drwxr-xr-x. 2 tbase tbase 4096 Nov 12  2020 bin
drwxr-xr-x. 4 tbase tbase 4096 Nov 12  2020 include
drwxr-xr-x. 4 tbase tbase 4096 Nov 12  2020 lib
drwxr-xr-x. 4 tbase tbase   35 Nov 12  2020 share
[root@node2 tbase_bin_v2.0]# pwd
/data/tbase/install/tbase_bin_v2.0

执行init all命令,完成集群初始化命令

[tbase@node1 pgxc_ctl]$ pgxc_ctl 
/bin/bash
Installing pgxc_ctl_bash script as /data/tbase/pgxc_ctl/pgxc_ctl_bash.
Installing pgxc_ctl_bash script as /data/tbase/pgxc_ctl/pgxc_ctl_bash.
Reading configuration using /data/tbase/pgxc_ctl/pgxc_ctl_bash --home /data/tbase/pgxc_ctl --configuration /data/tbase/pgxc_ctl/pgxc_ctl.conf
Finished reading configuration.
   ******** PGXC_CTL START ***************

Current directory: /data/tbase/pgxc_ctl
PGXC init all
Initialize GTM master
The files belonging to this GTM system will be owned by user "tbase".
This user must also own the server process.


fixing permissions on existing directory /data/tbase/data/gtm ... ok
creating configuration files ... ok
creating xlog dir ... ok

Success.
1:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData context:
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2055
2:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->gtm_control_version    = 20180716
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2056
3:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->xlog_seg_size          = 2097152
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2057
4:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->xlog_blcksz            = 4096
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2058
5:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->state                  = 1
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2059
6:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->CurrBytePos            = 4080
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2060
7:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->PrevBytePos            = 4080
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2061
8:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->thisTimeLineID         = 1
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2062
9:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->prevCheckPoint         = 0/0
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2063
10:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->checkPoint             = 0/1000
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2064
11:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->gts                    = 1000000000
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2065
12:1958545216:2020-11-12 17:33:45.003 CST -LOG:  ControlData->time                   = 1605173624
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2066
waiting for server to shut down....TBase create 1 worker thread.
Start sever loop start thread count 9 running thread count 9.
TBase GTM is ready to go!!
 done
server stopped
Done.
Start GTM master
server starting
1:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData context:
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2055
2:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->gtm_control_version    = 20180716
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2056
3:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->xlog_seg_size          = 2097152
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2057
4:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->xlog_blcksz            = 4096
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2058
5:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->state                  = 1
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2059
6:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->CurrBytePos            = 4178000
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2060
7:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->PrevBytePos            = 4177920
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2061
8:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->thisTimeLineID         = 1
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2062
9:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->prevCheckPoint         = 0/200000
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2063
10:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->checkPoint             = 0/400000
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2064
11:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->gts                    = 1301036123
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2065
12:15963968:2020-11-12 17:33:47.558 CST -LOG:  ControlData->time                   = 1605173626
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2066
Initialize GTM slave
The files belonging to this GTM system will be owned by user "tbase".
This user must also own the server process.


fixing permissions on existing directory /data/tbase/data/gtm ... ok
creating configuration files ... ok
creating xlog dir ... ok

Success.
Done.
Start GTM slaveserver starting
1:3702765376:2020-11-12 15:21:31.744 CST -LOG:  ControlData context:
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2055
2:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->gtm_control_version    = 20180716
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2056
3:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->xlog_seg_size          = 2097152
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2057
4:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->xlog_blcksz            = 4096
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2058
5:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->state                  = 1
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2059
6:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->CurrBytePos            = 4080
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2060
7:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->PrevBytePos            = 4080
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2061
8:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->thisTimeLineID         = 1
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2062
9:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->prevCheckPoint         = 0/0
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2063
10:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->checkPoint             = 0/1000
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2064
11:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->gts                    = 1000000000
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2065
12:3702765376:2020-11-12 15:21:31.745 CST -LOG:  ControlData->time                   = 1605165691
LOCATION:  GTM_PrintControlData, gtm_xlog.c:2066
Done.
Initialize all the coordinator masters.
Initialize coordinator master cn001.
Initialize coordinator master cn002.
get master gtm nodename:gtm.
get master gtm ip:192.168.199.240.
get master gtm port:50001.
The files belonging to this database system will be owned by user "tbase".
This user must also own the server process.

The database cluster will be initialized with locale "en_US.UTF-8".
The default database encoding has accordingly been set to "UTF8".
The default text search configuration will be set to "english".

Data page checksums are disabled.

fixing permissions on existing directory /data/tbase/data/coord ... ok
creating subdirectories ... ok
selecting default max_connections ... 100
selecting default shared_buffers ... 128MB
selecting dynamic shared memory implementation ... posix
creating configuration files ... ok
running bootstrap script ... 2020-11-12 17:33:50.513 CST [18181,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 17:33:50.670 CST [18181,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 17:33:50.842 CST [18181,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:294
2020-11-12 17:33:50.842 CST [18181,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:50.842 CST [18181,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:50.842 CST [18181,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:50.842 CST [18181,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:50.842 CST [18181,coord(0,0)] LOG:  shutdown committs
ok
performing post-bootstrap initialization ... creating cluster information ... 2020-11-12 17:33:50.891 CST [18187,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:51.039 CST [18187,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:51.039 CST [18187,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 17:33:51.070 CST [18187,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:1048
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:51.848 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:12
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:51.872 CST [18187,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:51.896 CST [18187,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:3
2020-11-12 17:33:51.896 CST [18187,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:51.896 CST [18187,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:51.896 CST [18187,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:51.896 CST [18187,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:51.896 CST [18187,coord(0,0)] LOG:  shutdown committs
ok
syncing data to disk ... ok
freezing database template0 ... 2020-11-12 17:33:52.024 CST [18194,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:52.179 CST [18194,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:52.179 CST [18194,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:52.207 CST [18194,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:52.207 CST [18194,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:52.207 CST [18194,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:52.207 CST [18194,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 17:33:52.208 CST [18194,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 17:33:52.208 CST [18194,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 17:33:52.208 CST [18194,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 17:33:52.208 CST [18194,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 17:33:52.252 CST [18194,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:22
2020-11-12 17:33:52.252 CST [18194,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:52.252 CST [18194,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:52.252 CST [18194,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:52.252 CST [18194,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:52.252 CST [18194,coord(0,0)] LOG:  shutdown committs
ok
freezing database template1 ... 2020-11-12 17:33:52.309 CST [18200,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:52.471 CST [18200,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:52.471 CST [18200,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 17:33:52.502 CST [18200,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 17:33:52.534 CST [18200,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 17:33:52.534 CST [18200,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:52.534 CST [18200,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:52.534 CST [18200,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:52.534 CST [18200,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:52.534 CST [18200,coord(0,0)] LOG:  shutdown committs
ok
freezing database postgres ... 2020-11-12 17:33:52.588 CST [18206,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:52.740 CST [18206,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:52.740 CST [18206,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 17:33:52.771 CST [18206,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 17:33:52.809 CST [18206,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 17:33:52.809 CST [18206,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:52.809 CST [18206,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:52.809 CST [18206,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:52.809 CST [18206,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:52.809 CST [18206,coord(0,0)] LOG:  shutdown committs
ok

WARNING: enabling "trust" authentication for local connections
You can change this by editing pg_hba.conf or using the option -A, or
--auth-local and --auth-host, the next time you run initdb.

Success.
get master gtm nodename:gtm.
get master gtm ip:192.168.199.240.
get master gtm port:50001.
The files belonging to this database system will be owned by user "tbase".
This user must also own the server process.

The database cluster will be initialized with locale "en_US.UTF-8".
The default database encoding has accordingly been set to "UTF8".
The default text search configuration will be set to "english".

Data page checksums are disabled.

fixing permissions on existing directory /data/tbase/data/coord ... ok
creating subdirectories ... ok
selecting default max_connections ... 100
selecting default shared_buffers ... 128MB
selecting dynamic shared memory implementation ... posix
creating configuration files ... ok
running bootstrap script ... 2020-11-12 15:21:33.113 CST [8027,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 15:21:33.290 CST [8027,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 15:21:33.471 CST [8027,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:294
2020-11-12 15:21:33.471 CST [8027,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:33.471 CST [8027,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:33.471 CST [8027,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:33.471 CST [8027,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:33.471 CST [8027,coord(0,0)] LOG:  shutdown committs
ok
performing post-bootstrap initialization ... creating cluster information ... 2020-11-12 15:21:33.522 CST [8033,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:33.701 CST [8033,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:33.701 CST [8033,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:33.737 CST [8033,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:33.738 CST [8033,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:33.738 CST [8033,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:33.738 CST [8033,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 15:21:33.738 CST [8033,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 15:21:33.738 CST [8033,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 15:21:33.738 CST [8033,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 15:21:33.738 CST [8033,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:1048
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:34.596 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:12
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:34.625 CST [8033,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:34.652 CST [8033,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:3
2020-11-12 15:21:34.652 CST [8033,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:34.652 CST [8033,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:34.652 CST [8033,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:34.652 CST [8033,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:34.652 CST [8033,coord(0,0)] LOG:  shutdown committs
ok
syncing data to disk ... ok
freezing database template0 ... 2020-11-12 15:21:34.781 CST [8040,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:34.952 CST [8040,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:34.952 CST [8040,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 15:21:34.982 CST [8040,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 15:21:35.024 CST [8040,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:22
2020-11-12 15:21:35.024 CST [8040,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:35.024 CST [8040,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:35.024 CST [8040,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:35.024 CST [8040,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:35.025 CST [8040,coord(0,0)] LOG:  shutdown committs
ok
freezing database template1 ... 2020-11-12 15:21:35.086 CST [8046,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:35.256 CST [8046,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:35.256 CST [8046,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:35.288 CST [8046,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:35.289 CST [8046,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:35.289 CST [8046,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:35.289 CST [8046,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 15:21:35.289 CST [8046,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 15:21:35.289 CST [8046,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 15:21:35.289 CST [8046,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 15:21:35.289 CST [8046,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 15:21:35.333 CST [8046,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 15:21:35.333 CST [8046,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:35.333 CST [8046,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:35.333 CST [8046,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:35.333 CST [8046,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:35.333 CST [8046,coord(0,0)] LOG:  shutdown committs
ok
freezing database postgres ... 2020-11-12 15:21:35.397 CST [8052,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:35.575 CST [8052,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:35.576 CST [8052,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 15:21:35.612 CST [8052,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 15:21:35.650 CST [8052,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 15:21:35.650 CST [8052,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:35.650 CST [8052,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:35.650 CST [8052,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:35.650 CST [8052,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:35.650 CST [8052,coord(0,0)] LOG:  shutdown committs
ok

WARNING: enabling "trust" authentication for local connections
You can change this by editing pg_hba.conf or using the option -A, or
--auth-local and --auth-host, the next time you run initdb.

Success.
Done.
Starting coordinator master.
Starting coordinator master cn001
Starting coordinator master cn002
2020-11-12 09:33:54.329 GMT [18620,coord(18620,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 09:33:54.329 GMT [18620,coord(18620,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 17:33:54.331 CST [18620,coord(18620,0)] LOG:  listening on IPv4 address "0.0.0.0", port 30004
2020-11-12 17:33:54.331 CST [18620,coord(18620,0)] LOG:  listening on IPv6 address "::", port 30004
2020-11-12 17:33:54.333 CST [18620,coord(18620,0)] LOG:  listening on Unix socket "/tmp/.s.PGSQL.30004"
2020-11-12 17:33:54.338 CST [18620,coord(18620,0)] LOG:  init committs shmem.
2020-11-12 17:33:54.466 CST [18620,coord(18620,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:54.466 CST [18620,coord(18620,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:54.493 CST [18620,coord(18620,0)] LOG:  redirecting log output to logging collector process
2020-11-12 17:33:54.493 CST [18620,coord(18620,0)] HINT:  Future log output will appear in directory "pg_log".
2020-11-12 07:21:37.629 GMT [8395,coord(8395,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 07:21:37.630 GMT [8395,coord(8395,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 15:21:37.632 CST [8395,coord(8395,0)] LOG:  listening on IPv4 address "0.0.0.0", port 30004
2020-11-12 15:21:37.632 CST [8395,coord(8395,0)] LOG:  listening on IPv6 address "::", port 30004
2020-11-12 15:21:37.640 CST [8395,coord(8395,0)] LOG:  listening on Unix socket "/tmp/.s.PGSQL.30004"
2020-11-12 15:21:37.646 CST [8395,coord(8395,0)] LOG:  init committs shmem.
2020-11-12 15:21:37.786 CST [8395,coord(8395,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:37.786 CST [8395,coord(8395,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:37.815 CST [8395,coord(8395,0)] LOG:  redirecting log output to logging collector process
2020-11-12 15:21:37.815 CST [8395,coord(8395,0)] HINT:  Future log output will appear in directory "pg_log".
Done.
Initialize all the datanode masters.
Initialize the datanode master dn001.
Initialize the datanode master dn002.
get master gtm nodename:gtm.
get master gtm ip:192.168.199.240.
get master gtm port:50001.
The files belonging to this database system will be owned by user "tbase".
This user must also own the server process.

The database cluster will be initialized with locale "en_US.UTF-8".
The default database encoding has accordingly been set to "UTF8".
The default text search configuration will be set to "english".

Data page checksums are disabled.

fixing permissions on existing directory /data/tbase/data/dn001 ... ok
creating subdirectories ... ok
selecting default max_connections ... 100
selecting default shared_buffers ... 128MB
selecting dynamic shared memory implementation ... posix
creating configuration files ... ok
running bootstrap script ... 2020-11-12 17:33:55.701 CST [18834,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 17:33:55.857 CST [18834,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 17:33:56.012 CST [18834,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:294
2020-11-12 17:33:56.012 CST [18834,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:56.012 CST [18834,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:56.012 CST [18834,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:56.012 CST [18834,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:56.012 CST [18834,coord(0,0)] LOG:  shutdown committs
ok
performing post-bootstrap initialization ... creating cluster information ... 2020-11-12 17:33:56.056 CST [18840,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:56.212 CST [18840,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:56.212 CST [18840,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 17:33:56.242 CST [18840,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:1048
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:57.040 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:12
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:57.064 CST [18840,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 17:33:57.086 CST [18840,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:3
2020-11-12 17:33:57.086 CST [18840,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:57.086 CST [18840,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:57.086 CST [18840,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:57.086 CST [18840,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:57.086 CST [18840,coord(0,0)] LOG:  shutdown committs
ok
syncing data to disk ... ok
freezing database template0 ... 2020-11-12 17:33:57.214 CST [18847,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:57.368 CST [18847,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:57.368 CST [18847,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 17:33:57.398 CST [18847,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 17:33:57.431 CST [18847,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:22
2020-11-12 17:33:57.431 CST [18847,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:57.431 CST [18847,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:57.431 CST [18847,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:57.431 CST [18847,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:57.432 CST [18847,coord(0,0)] LOG:  shutdown committs
ok
freezing database template1 ... 2020-11-12 17:33:57.489 CST [18853,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:57.639 CST [18853,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:57.639 CST [18853,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 17:33:57.666 CST [18853,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 17:33:57.702 CST [18853,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 17:33:57.702 CST [18853,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:57.702 CST [18853,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:57.702 CST [18853,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:57.702 CST [18853,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:57.702 CST [18853,coord(0,0)] LOG:  shutdown committs
ok
freezing database postgres ... 2020-11-12 17:33:57.757 CST [18859,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:33:57.917 CST [18859,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:33:57.917 CST [18859,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  startup commitTS.
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  activate commit ts.
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 17:33:57.950 CST [18859,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 17:33:57.989 CST [18859,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 17:33:57.989 CST [18859,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 17:33:57.989 CST [18859,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 17:33:57.989 CST [18859,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 17:33:57.989 CST [18859,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 17:33:57.989 CST [18859,coord(0,0)] LOG:  shutdown committs
ok

WARNING: enabling "trust" authentication for local connections
You can change this by editing pg_hba.conf or using the option -A, or
--auth-local and --auth-host, the next time you run initdb.

Success.
get master gtm nodename:gtm.
get master gtm ip:192.168.199.240.
get master gtm port:50001.
The files belonging to this database system will be owned by user "tbase".
This user must also own the server process.

The database cluster will be initialized with locale "en_US.UTF-8".
The default database encoding has accordingly been set to "UTF8".
The default text search configuration will be set to "english".

Data page checksums are disabled.

fixing permissions on existing directory /data/tbase/data/dn002 ... ok
creating subdirectories ... ok
selecting default max_connections ... 100
selecting default shared_buffers ... 128MB
selecting dynamic shared memory implementation ... posix
creating configuration files ... ok
running bootstrap script ... 2020-11-12 15:21:39.168 CST [8588,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 15:21:39.336 CST [8588,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 15:21:39.517 CST [8588,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:294
2020-11-12 15:21:39.517 CST [8588,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:39.517 CST [8588,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:39.517 CST [8588,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:39.517 CST [8588,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:39.517 CST [8588,coord(0,0)] LOG:  shutdown committs
ok
performing post-bootstrap initialization ... creating cluster information ... 2020-11-12 15:21:39.576 CST [8594,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:39.750 CST [8594,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:39.750 CST [8594,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 0 xid 3 partition 0
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  startup CLOG next xid 3 latest page number 0
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  Trim CLOG next xid 3 latest page number 0
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  Trim committs next xid 3 latest page number 0 entryno 3
2020-11-12 15:21:39.782 CST [8594,coord(0,0)] LOG:  zero out the remaining page starting from byteno 72 len BLCKSZ -byteno 8120 entryno 3 sizeofentry 18
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:1048
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:40.671 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE template0 IS_TEMPLATE = true ALLOW_CONNECTIONS = false;
    
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:12
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:40.700 CST [8594,coord(0,0)] STATEMENT:  CREATE DATABASE postgres;
    
2020-11-12 15:21:40.732 CST [8594,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:3
2020-11-12 15:21:40.732 CST [8594,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:40.732 CST [8594,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:40.732 CST [8594,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:40.732 CST [8594,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:40.732 CST [8594,coord(0,0)] LOG:  shutdown committs
ok
syncing data to disk ... ok
freezing database template0 ... 2020-11-12 15:21:40.872 CST [8601,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:41.047 CST [8601,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:41.048 CST [8601,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 15:21:41.077 CST [8601,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 15:21:41.122 CST [8601,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:22
2020-11-12 15:21:41.122 CST [8601,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:41.122 CST [8601,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:41.122 CST [8601,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:41.122 CST [8601,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:41.123 CST [8601,coord(0,0)] LOG:  shutdown committs
ok
freezing database template1 ... 2020-11-12 15:21:41.186 CST [8607,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:41.346 CST [8607,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:41.346 CST [8607,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 15:21:41.377 CST [8607,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 15:21:41.418 CST [8607,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 15:21:41.418 CST [8607,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:41.418 CST [8607,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:41.418 CST [8607,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:41.418 CST [8607,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:41.419 CST [8607,coord(0,0)] LOG:  shutdown committs
ok
freezing database postgres ... 2020-11-12 15:21:41.472 CST [8613,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:41.656 CST [8613,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:41.656 CST [8613,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  read latestCommitTs 1 read latestGTS 1
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  startup commitTS.
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  activate commit ts.
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  ActivateCommitTs: committs latest page number 1 xid 598 partition 1
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  startup CLOG next xid 598 latest page number 0
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  Trim CLOG next xid 598 latest page number 0
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  Trim committs next xid 598 latest page number 1 entryno 143
2020-11-12 15:21:41.686 CST [8613,coord(0,0)] LOG:  zero out the remaining page starting from byteno 2592 len BLCKSZ -byteno 5600 entryno 143 sizeofentry 18
2020-11-12 15:21:41.727 CST [8613,coord(0,0)] LOG:  CHECKPOINT:in one round, buffer crypted write:0, normal buffer write:13
2020-11-12 15:21:41.727 CST [8613,coord(0,0)] LOG:  detail for workers:id:0-bufs:0, 
2020-11-12 15:21:41.727 CST [8613,coord(0,0)] LOG:  detail for workers:id:1-bufs:0, 
2020-11-12 15:21:41.727 CST [8613,coord(0,0)] LOG:  detail for workers:id:2-bufs:0, 
2020-11-12 15:21:41.727 CST [8613,coord(0,0)] LOG:  detail for workers:id:3-bufs:0, 
2020-11-12 15:21:41.728 CST [8613,coord(0,0)] LOG:  shutdown committs
ok

WARNING: enabling "trust" authentication for local connections
You can change this by editing pg_hba.conf or using the option -A, or
--auth-local and --auth-host, the next time you run initdb.

Success.
Done.
Starting all the datanode masters.
Starting datanode master dn001.
Starting datanode master dn002.
2020-11-12 09:34:00.364 GMT [19523,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 09:34:00.364 GMT [19523,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 17:34:00.366 CST [19523,coord(0,0)] LOG:  listening on IPv4 address "0.0.0.0", port 40004
2020-11-12 17:34:00.366 CST [19523,coord(0,0)] LOG:  listening on IPv6 address "::", port 40004
2020-11-12 17:34:00.367 CST [19523,coord(0,0)] LOG:  listening on Unix socket "/tmp/.s.PGSQL.40004"
2020-11-12 17:34:00.407 CST [19523,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:34:00.561 CST [19523,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:34:00.561 CST [19523,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:34:00.591 CST [19523,coord(0,0)] LOG:  redirecting log output to logging collector process
2020-11-12 17:34:00.591 CST [19523,coord(0,0)] HINT:  Future log output will appear in directory "pg_log".
2020-11-12 07:21:44.352 GMT [9176,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 07:21:44.352 GMT [9176,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 15:21:44.354 CST [9176,coord(0,0)] LOG:  listening on IPv4 address "0.0.0.0", port 40004
2020-11-12 15:21:44.354 CST [9176,coord(0,0)] LOG:  listening on IPv6 address "::", port 40004
2020-11-12 15:21:44.356 CST [9176,coord(0,0)] LOG:  listening on Unix socket "/tmp/.s.PGSQL.40004"
2020-11-12 15:21:44.403 CST [9176,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:44.586 CST [9176,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:44.586 CST [9176,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:44.622 CST [9176,coord(0,0)] LOG:  redirecting log output to logging collector process
2020-11-12 15:21:44.622 CST [9176,coord(0,0)] HINT:  Future log output will appear in directory "pg_log".
Done.
Initialize all the datanode slaves.
Initialize datanode slave dn001
Initialize datanode slave dn002
ERROR: target directory (/data/tbase/data/dn001) exists and not empty. Skip Datanode initilialization
Starting all the datanode slaves.
Starting datanode slave dn001.
Starting datanode slave dn002.
2020-11-12 07:21:48.033 GMT [9808,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 07:21:48.033 GMT [9808,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 15:21:48.035 CST [9808,coord(0,0)] LOG:  listening on IPv4 address "0.0.0.0", port 50004
2020-11-12 15:21:48.035 CST [9808,coord(0,0)] LOG:  listening on IPv6 address "::", port 50004
2020-11-12 15:21:48.036 CST [9808,coord(0,0)] LOG:  listening on Unix socket "/tmp/.s.PGSQL.50004"
2020-11-12 15:21:48.080 CST [9808,coord(0,0)] LOG:  init committs shmem.
2020-11-12 15:21:48.263 CST [9808,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 15:21:48.263 CST [9808,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 15:21:48.296 CST [9808,coord(0,0)] LOG:  redirecting log output to logging collector process
2020-11-12 15:21:48.296 CST [9808,coord(0,0)] HINT:  Future log output will appear in directory "pg_log".
2020-11-12 09:34:03.671 GMT [20296,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 09:34:03.671 GMT [20296,coord(0,0)] LOG:  skipping missing configuration file "/data/tbase/global/global_tbase.conf"
2020-11-12 17:34:03.673 CST [20296,coord(0,0)] LOG:  listening on IPv4 address "0.0.0.0", port 54004
2020-11-12 17:34:03.673 CST [20296,coord(0,0)] LOG:  listening on IPv6 address "::", port 54004
2020-11-12 17:34:03.674 CST [20296,coord(0,0)] LOG:  listening on Unix socket "/tmp/.s.PGSQL.54004"
2020-11-12 17:34:03.714 CST [20296,coord(0,0)] LOG:  init committs shmem.
2020-11-12 17:34:03.899 CST [20296,coord(0,0)] LOG:  could not open file "global/pg_crypt_key.map":No such file or directory for bufFile merging.
2020-11-12 17:34:03.899 CST [20296,coord(0,0)] LOG:  could not open file "global/pg_rel_crypt.map":No such file or directory for bufFile merging.
2020-11-12 17:34:03.931 CST [20296,coord(0,0)] LOG:  redirecting log output to logging collector process
2020-11-12 17:34:03.931 CST [20296,coord(0,0)] HINT:  Future log output will appear in directory "pg_log".
Done.
ALTER NODE cn001 WITH (HOST='192.168.199.240', PORT=30004);
ALTER NODE
CREATE NODE cn002 WITH (TYPE='coordinator', HOST='192.168.199.241', PORT=30004);
CREATE NODE
CREATE NODE dn001 WITH (TYPE='datanode', HOST='192.168.199.240', PORT=40004, PRIMARY, PREFERRED);
CREATE NODE
CREATE NODE dn002 WITH (TYPE='datanode', HOST='192.168.199.241', PORT=40004);
CREATE NODE
SELECT pgxc_pool_reload();
 pgxc_pool_reload 
------------------
 t
(1 row)

CREATE NODE cn001 WITH (TYPE='coordinator', HOST='192.168.199.240', PORT=30004);
CREATE NODE
ALTER NODE cn002 WITH (HOST='192.168.199.241', PORT=30004);
ALTER NODE
CREATE NODE dn001 WITH (TYPE='datanode', HOST='192.168.199.240', PORT=40004, PRIMARY);
CREATE NODE
CREATE NODE dn002 WITH (TYPE='datanode', HOST='192.168.199.241', PORT=40004, PREFERRED);
CREATE NODE
SELECT pgxc_pool_reload();
 pgxc_pool_reload 
------------------
 t
(1 row)

Done.
EXECUTE DIRECT ON (dn001) 'CREATE NODE cn001 WITH (TYPE=''coordinator'', HOST=''192.168.199.240'', PORT=30004)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn001) 'CREATE NODE cn002 WITH (TYPE=''coordinator'', HOST=''192.168.199.241'', PORT=30004)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn001) 'ALTER NODE dn001 WITH (TYPE=''datanode'', HOST=''192.168.199.240'', PORT=40004, PRIMARY, PREFERRED)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn001) 'CREATE NODE dn002 WITH (TYPE=''datanode'', HOST=''192.168.199.241'', PORT=40004, PREFERRED)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn001) 'SELECT pgxc_pool_reload()';
 pgxc_pool_reload 
------------------
 t
(1 row)

EXECUTE DIRECT ON (dn002) 'CREATE NODE cn001 WITH (TYPE=''coordinator'', HOST=''192.168.199.240'', PORT=30004)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn002) 'CREATE NODE cn002 WITH (TYPE=''coordinator'', HOST=''192.168.199.241'', PORT=30004)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn002) 'CREATE NODE dn001 WITH (TYPE=''datanode'', HOST=''192.168.199.240'', PORT=40004, PRIMARY, PREFERRED)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn002) 'ALTER NODE dn002 WITH (TYPE=''datanode'', HOST=''192.168.199.241'', PORT=40004, PREFERRED)';
EXECUTE DIRECT
EXECUTE DIRECT ON (dn002) 'SELECT pgxc_pool_reload()';
 pgxc_pool_reload 
------------------
 t
(1 row)

Done.

查看集群情况
PGXC monitor all
Running: gtm master
Not running: gtm slave
Running: coordinator master cn001
Running: coordinator master cn002
Running: datanode master dn001
Running: datanode slave dn001
Running: datanode master dn002
Running: datanode slave dn002

访问集群(通过cn节点)

[tbase@node1 pgxc_ctl]$ psql -h 192.168.199.240 -p 30004 -d postgres -U tbase
psql (PostgreSQL 10.0 TBase V2)
Type "help" for help.

postgres=# select * from pgxc_node;
 node_name | node_type | node_port |    node_host    | nodeis_primary | nodeis_preferred |  node_id   | node_cluster_name 
-----------+-----------+-----------+-----------------+----------------+------------------+------------+-------------------
 gtm       | G         |     50001 | 192.168.199.240 | t              | f                |  428125959 | tbase_cluster
 cn001     | C         |     30004 | 192.168.199.240 | f              | f                | -264077367 | tbase_cluster
 cn002     | C         |     30004 | 192.168.199.241 | f              | f                | -674870440 | tbase_cluster
 dn001     | D         |     40004 | 192.168.199.240 | t              | t                | 2142761564 | tbase_cluster
 dn002     | D         |     40004 | 192.168.199.241 | f              | f                |  -17499968 | tbase_cluster
(5 rows)

创建default group以及sharding表(使用数据库前需创建)
TBase使用datanode group来增加节点的管理灵活度,要求有一个default group才能使用,因此需要预先创建;一般情况下,会将节点的所有datanode节点加入到default group里 另外一方面,TBase的数据分布为了增加灵活度,加了中间逻辑层来维护数据记录到物理节点的映射,我们叫sharding,所以需要预先创建sharding

postgres=# create default node group default_group  with (dn001,dn002);
CREATE NODE GROUP
postgres=# create sharding group to group default_group;
CREATE SHARDING GROUP

相关操作命令

# 指定基础目录,指定配置文件
pgxc_ctl --home /data/tbase/ -c ./pgxc_ctl/pgxc_ctl.conf
# 二进制分发
> deploy all
# 集群初始化
> init all
# 显示配置
> show config all
# 启停服务
> stop all -m fast
> start all
# 监控集群
> monitor all
# 清除集群:用于重新部署
> clean all

 

  • 0
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
TBase DataX是一个开源的数据传输工具,用于在不同数据源之间进行数据的传输和同步。它可以支持包括关系型数据库、大数据存储系统、文件系统等多种数据源之间的数据传输。 TBase DataX的工作原理是通过插件化的方式,将不同数据源的读取和写入过程抽象成不同的插件,以实现数据的源端读取和目标端写入。用户可以通过配置文件来指定读取和写入的数据源,并定义数据的转换规则和筛选条件。 相对于传统的数据传输工具,TBase DataX具有以下几个特点: 1. 插件化架构:TBase DataX采用了插件化的架构设计,使得它可以灵活地支持不同数据源的读取和写入操作。用户可以根据实际需求选择不同的插件,无需修改核心代码。 2. 分布式传输:TBase DataX支持将数据传输任务分发到多台机器上进行并发处理,提高了传输的效率和速度。同时,它还提供了故障转移和容错机制,保证数据传输的可靠性。 3. 简单易用:TBase DataX提供了简洁的配置文件格式,用户可以通过简单的配置来完成数据传输任务。同时,它还提供了丰富的日志和监控功能,方便用户进行任务的管理和监控。 总的来说,TBase DataX是一个功能强大、灵活易用的数据传输工具,可以帮助用户快速实现不同数据源之间的数据传输和同步。无论是大数据环境下的数据迁移,还是数据仓库的数据同步,TBase DataX都能提供稳定可靠的解决方案。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值