AT
await conn.sql(f"insert into info(id, title, body) "
f"values ( {row['id']}, '{row['title']}', '{row['body']}' )" )
Size: a a a
AT
AT
HT
A
2021-01-22 16:04:47.650 [802522] main/110/applier/user@51. I> will retry every 60.00 second
2021-01-22 16:05:47.736 [802522] main/110/applier/user@51. I> authenticated
2021-01-22 16:05:47.758 [802522] main/110/applier/user@51. I> subscribed
2021-01-22 16:05:47.758 [802522] main/110/applier/user@51. I> remote vclock {1: 160336292617, 2: 66085717162} local vclock {1: 160335568147, 2: 66085717162}
2021-01-22 16:05:53.556 [802522] main/123/applierw/user@51 C> leaving orphan mode
2021-01-22 16:05:57.578 [802522] main/110/applier/user@51. I> can't read row
2021-01-22 16:05:57.578 [802522] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
coio.cc:340 !> SystemError timed out: Operation timed out
relay/repl:6358/101/main C> exiting the relay loop
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
802522 taranto+ 20 0 23.3g 14.3g 15988 S 0.0 22.8 6:20.25 tarantool
2021-01-22 19:19:05.649 [689211] snapshot/101/main C> 23.1M rows written
2021-01-22 19:19:05.704 [689211] snapshot/101/main I> done
2021-01-22 19:19:05.705 [689211] main/102/app I> ready to accept requests
2021-01-22 19:19:05.705 [689211] main/102/app I> synchronizing with 1 replicas
2021-01-22 19:19:05.723 [689211] main/110/applier/user@51. I> subscribed
2021-01-22 19:19:05.723 [689211] main/110/applier/user@51. I> remote vclock {1: 160478605221, 2: 66085717162} local vclock {1: 160476416837, 2: 66085717162}
2021-01-22 19:19:22.038 [689211] main/111/applierw/user@51 C> leaving orphan mode
2021-01-22 19:19:22.038 [689211] main/102/app I> replica set sync complete
2021-01-22 19:19:22.038 [689211] main/102/app C> leaving orphan mode
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'checkpoint_interval' configuration option to 0
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication_timeout' configuration option to 60
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'memtx_memory' configuration option to 10000000000
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'net_msg_max' configuration option to 4000
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'listen' configuration option to "3311"
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication_connect_quorum' configuration option to 1
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'read_only' configuration option to true
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'readahead' configuration option to 32640
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication' configuration option to ["user@ip_master:port"]
2021-01-22 19:19:22.038 [689211] main C> entering the event loop
2021-01-22 19:19:26.057 [689211] main/110/applier/user@51. I> can't read row
2021-01-22 19:19:26.057 [689211] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
MA
2021-01-22 19:19:05.649 [689211] snapshot/101/main C> 23.1M rows written
2021-01-22 19:19:05.704 [689211] snapshot/101/main I> done
2021-01-22 19:19:05.705 [689211] main/102/app I> ready to accept requests
2021-01-22 19:19:05.705 [689211] main/102/app I> synchronizing with 1 replicas
2021-01-22 19:19:05.723 [689211] main/110/applier/user@51. I> subscribed
2021-01-22 19:19:05.723 [689211] main/110/applier/user@51. I> remote vclock {1: 160478605221, 2: 66085717162} local vclock {1: 160476416837, 2: 66085717162}
2021-01-22 19:19:22.038 [689211] main/111/applierw/user@51 C> leaving orphan mode
2021-01-22 19:19:22.038 [689211] main/102/app I> replica set sync complete
2021-01-22 19:19:22.038 [689211] main/102/app C> leaving orphan mode
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'checkpoint_interval' configuration option to 0
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication_timeout' configuration option to 60
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'memtx_memory' configuration option to 10000000000
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'net_msg_max' configuration option to 4000
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'listen' configuration option to "3311"
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication_connect_quorum' configuration option to 1
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'read_only' configuration option to true
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'readahead' configuration option to 32640
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication' configuration option to ["user@ip_master:port"]
2021-01-22 19:19:22.038 [689211] main C> entering the event loop
2021-01-22 19:19:26.057 [689211] main/110/applier/user@51. I> can't read row
2021-01-22 19:19:26.057 [689211] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
remote vclock {1: 160478605221, 2: 66085717162} local vclock {1: 160476416837, 2: 66085717162}
— дельта 2M транзакций.replica set sync complete
(т.е. реплика догналась со вполне нормальной скоростью 128krps)MA
2021-01-22 19:19:05.649 [689211] snapshot/101/main C> 23.1M rows written
2021-01-22 19:19:05.704 [689211] snapshot/101/main I> done
2021-01-22 19:19:05.705 [689211] main/102/app I> ready to accept requests
2021-01-22 19:19:05.705 [689211] main/102/app I> synchronizing with 1 replicas
2021-01-22 19:19:05.723 [689211] main/110/applier/user@51. I> subscribed
2021-01-22 19:19:05.723 [689211] main/110/applier/user@51. I> remote vclock {1: 160478605221, 2: 66085717162} local vclock {1: 160476416837, 2: 66085717162}
2021-01-22 19:19:22.038 [689211] main/111/applierw/user@51 C> leaving orphan mode
2021-01-22 19:19:22.038 [689211] main/102/app I> replica set sync complete
2021-01-22 19:19:22.038 [689211] main/102/app C> leaving orphan mode
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'checkpoint_interval' configuration option to 0
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication_timeout' configuration option to 60
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'memtx_memory' configuration option to 10000000000
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'net_msg_max' configuration option to 4000
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'listen' configuration option to "3311"
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication_connect_quorum' configuration option to 1
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'read_only' configuration option to true
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'readahead' configuration option to 32640
2021-01-22 19:19:22.038 [689211] main/102/app I> set 'replication' configuration option to ["user@ip_master:port"]
2021-01-22 19:19:22.038 [689211] main C> entering the event loop
2021-01-22 19:19:26.057 [689211] main/110/applier/user@51. I> can't read row
2021-01-22 19:19:26.057 [689211] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
replication_connect_timeout = 60
(вместо дефолтных 30) replication_timeout = 3
вместо дефолтного 1A
replication_connect_timeout = 60
(вместо дефолтных 30) replication_timeout = 3
вместо дефолтного 1replication_timeout = 60;
replication_connect_timeout = 60;
replication_timeout = 60;
A
replication_connect_timeout = 60
(вместо дефолтных 30) replication_timeout = 3
вместо дефолтного 12021-01-22 19:48:35.456 [2140313] main/102/app I> ready to accept requests
2021-01-22 19:48:35.456 [2140313] main/102/app I> synchronizing with 1 replicas
2021-01-22 19:48:35.475 [2140313] main/110/applier/user@51. I> subscribed
2021-01-22 19:48:35.475 [2140313] main/110/applier/user@51. I> remote vclock {1: 160500452415, 2: 66085717162} local vclock {1: 160499135976, 2: 66085717162}
2021-01-22 19:48:45.265 [2140313] main/111/applierw/user@51 C> leaving orphan mode
2021-01-22 19:48:45.265 [2140313] main/102/app I> replica set sync complete
2021-01-22 19:48:45.265 [2140313] main/102/app C> leaving orphan mode
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'checkpoint_interval' configuration option to 0
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_connect_timeout' configuration option to 60
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_timeout' configuration option to 60
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'memtx_memory' configuration option to 10000000000
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'net_msg_max' configuration option to 4000
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'listen' configuration option to "3311"
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_connect_quorum' configuration option to 1
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'read_only' configuration option to true
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'readahead' configuration option to 32640
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication' configuration option to ["user@ip_master:port"]
2021-01-22 19:48:45.265 [2140313] main C> entering the event loop
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. I> can't read row
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. I> will retry every 60.00 second
MA
replication_timeout = 60;
replication_connect_timeout = 60;
replication_timeout = 60;
MA
2021-01-22 19:48:35.456 [2140313] main/102/app I> ready to accept requests
2021-01-22 19:48:35.456 [2140313] main/102/app I> synchronizing with 1 replicas
2021-01-22 19:48:35.475 [2140313] main/110/applier/user@51. I> subscribed
2021-01-22 19:48:35.475 [2140313] main/110/applier/user@51. I> remote vclock {1: 160500452415, 2: 66085717162} local vclock {1: 160499135976, 2: 66085717162}
2021-01-22 19:48:45.265 [2140313] main/111/applierw/user@51 C> leaving orphan mode
2021-01-22 19:48:45.265 [2140313] main/102/app I> replica set sync complete
2021-01-22 19:48:45.265 [2140313] main/102/app C> leaving orphan mode
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'checkpoint_interval' configuration option to 0
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_connect_timeout' configuration option to 60
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_timeout' configuration option to 60
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'memtx_memory' configuration option to 10000000000
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'net_msg_max' configuration option to 4000
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'listen' configuration option to "3311"
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_connect_quorum' configuration option to 1
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'read_only' configuration option to true
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'readahead' configuration option to 32640
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication' configuration option to ["user@ip_master:port"]
2021-01-22 19:48:45.265 [2140313] main C> entering the event loop
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. I> can't read row
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. I> will retry every 60.00 second
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
MA
local r = {} for k,v in pairs(box.cfg) do if k:match"timeout" then r[k]=v end end return r
---
- replication_connect_timeout: 30
vinyl_timeout: 60
election_timeout: 5
replication_sync_timeout: 300
replication_synchro_timeout: 5
replication_timeout: 1
...
A
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
KN
2021-01-22 19:48:35.456 [2140313] main/102/app I> ready to accept requests
2021-01-22 19:48:35.456 [2140313] main/102/app I> synchronizing with 1 replicas
2021-01-22 19:48:35.475 [2140313] main/110/applier/user@51. I> subscribed
2021-01-22 19:48:35.475 [2140313] main/110/applier/user@51. I> remote vclock {1: 160500452415, 2: 66085717162} local vclock {1: 160499135976, 2: 66085717162}
2021-01-22 19:48:45.265 [2140313] main/111/applierw/user@51 C> leaving orphan mode
2021-01-22 19:48:45.265 [2140313] main/102/app I> replica set sync complete
2021-01-22 19:48:45.265 [2140313] main/102/app C> leaving orphan mode
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'checkpoint_interval' configuration option to 0
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_connect_timeout' configuration option to 60
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_timeout' configuration option to 60
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'memtx_memory' configuration option to 10000000000
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'net_msg_max' configuration option to 4000
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'listen' configuration option to "3311"
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication_connect_quorum' configuration option to 1
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'read_only' configuration option to true
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'readahead' configuration option to 32640
2021-01-22 19:48:45.265 [2140313] main/102/app I> set 'replication' configuration option to ["user@ip_master:port"]
2021-01-22 19:48:45.265 [2140313] main C> entering the event loop
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. I> can't read row
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. xrow.c:1079 E> ER_SYSTEM: timed out
2021-01-22 19:48:49.285 [2140313] main/110/applier/user@51. I> will retry every 60.00 second
A
local r = {} for k,v in pairs(box.cfg) do if k:match"timeout" then r[k]=v end end return r
---
- replication_connect_timeout: 30
vinyl_timeout: 60
election_timeout: 5
replication_sync_timeout: 300
replication_synchro_timeout: 5
replication_timeout: 1
...
localhost:3311> local r = {} for k,v in pairs(box.cfg) do if k:match"timeout" then r[k]=v end end return r
---
- replication_sync_timeout: 300
replication_connect_timeout: 60
vinyl_timeout: 60
replication_timeout: 60
...
A
MA
final data received
(https://github.com/tarantool/tarantool/blob/b9c4c7c04ae99c5d00124f6c578b7f19a0b98174/src/box/applier.cc#L915) мы в статусе APPLIER_FINAL_JOINentering the event loop
, что очень похоже на replication_timeout=1do
local ffi = require 'ffi'
ffi.cdef[[ extern double replication_timeout; ]]
ffi.C.replication_timeout = 5
end
MA