Re: PostgreSQL-11 Streaming Replication Slave Recovering

Поиск
Список
Период
Сортировка
От Ali Mumcu
Тема Re: PostgreSQL-11 Streaming Replication Slave Recovering
Дата
Msg-id CAByegeLEQQf+=2Qx-rq6SRm-Q45u66s_0J4YpBtBeuKCVjmXRA@mail.gmail.com
обсуждение исходный текст
Ответ на PostgreSQL-11 Streaming Replication Slave Recovering  (Ali Mumcu <alimumcu1077@gmail.com>)
Список pgsql-general
Also this is postgresql Log(Debug1 level) . after i restart slave node this logs accours.
/var/lib/pgsql/11/data/log/postgresql-Fri.log
2019-03-22 12:17:57.869 +03 [31760] LOG:  redo starts at 0/C000098
2019-03-22 12:17:57.869 +03 [31760] LOG:  consistent recovery state reached at 0/C0000D0
2019-03-22 12:17:57.869 +03 [31760] LOG:  invalid record length at 0/C0000D0: wanted 24, got 0
2019-03-22 12:17:57.870 +03 [31757] LOG:  database system is ready to accept read only connections
2019-03-22 12:17:57.877 +03 [31764] LOG:  started streaming WAL from primary at 0/C000000 on timeline 1


Ali Mumcu <alimumcu1077@gmail.com>, 22 Mar 2019 Cum, 12:07 tarihinde şunu yazdı:
Hello Friends,

I wanna to create Streaming Replication with 2 Node(1 Master, 1 Slave)
After i create streaming replication, streaming is okay , and than  when i add new record on master , than on slave records occurs  autamaticly.

but When i look service status on slave server i "see startup recovering 00000001000000000000000A"


[root@slave]# systemctl status postgresql-11
● postgresql-11.service - PostgreSQL 11 database server
   Loaded: loaded (/usr/lib/systemd/system/postgresql-11.service; disabled; vendor preset: disabled)
   Active: active (running) since Fri 2019-03-22 11:52:17 +03; 22s ago
     Docs: https://www.postgresql.org/docs/11/static/
  Process: 29349 ExecStartPre=/usr/pgsql-11/bin/postgresql-11-check-db-dir ${PGDATA} (code=exited, status=0/SUCCESS)
 Main PID: 29355 (postmaster)
   CGroup: /system.slice/postgresql-11.service
           ├─29355 /usr/pgsql-11/bin/postmaster -D /var/lib/pgsql/11/data/
           ├─29357 postgres: logger
           ├─29358 postgres: startup   recovering 000000010000000000000008
           ├─29359 postgres: checkpointer
           ├─29360 postgres: background writer
           ├─29361 postgres: stats collector
           └─29362 postgres: walreceiver   streaming 0/A0000D0

when on master create new wal_file(like  000000010000000000000009)  and then on slave this is updating on slave like  "startup   recovering 000000010000000000000009  "

Is that a problem or not i dont know?

Master And Slave Postgresql.conf file
listen_addresses = '*'
wal_level = replica
synchronous_commit = on
max_wal_senders = 10
wal_keep_segments = 64
hot_standby = on
hot_standby_feedback = on 

Slave Recovery.conf file
standby_mode = on
primary_conninfo = 'host=master_ip  user=user password=password
application_name=slave'
recovery_target_timeline = 'latest' 


Also i trace postgresql process on slave Node  . This is results
[root@slave os1077]# strace -p 29358
strace: Process 29358 attached
epoll_wait(4, [], 1, 639)               = 0
close(4)                                = 0
read(7, 0x7ffe72a52007, 1)              = -1 EAGAIN (Resource temporarily unavailable)
epoll_create1(EPOLL_CLOEXEC)            = 4
epoll_ctl(4, EPOLL_CTL_ADD, 11, {EPOLLIN|EPOLLERR|EPOLLHUP, {u32=34908528, u64=34908528}}) = 0
epoll_ctl(4, EPOLL_CTL_ADD, 7, {EPOLLIN|EPOLLERR|EPOLLHUP, {u32=34908552, u64=34908552}}) = 0
epoll_wait(4, strace: Process 29358 detached
 <detached ...>




--
ALİ MUMCU 
İSTANBUL ÜNİVERSİTESİ
BİLGİ İŞLEM DAİRE BAŞKANLIĞI 
Dahili:11210

В списке pgsql-general по дате отправления:

Предыдущее
От: Ali Mumcu
Дата:
Сообщение: PostgreSQL-11 Streaming Replication Slave Recovering
Следующее
От: Aleš Zelený
Дата:
Сообщение: Logical replication - DDL sub transactions for script executed insingle transaction?