pglogical
pglogical copied to clipboard
ERROR: data stream ended
Recently, I encounter an error abort "data stream ended", I inspect the code and find it happens here.
Here is the error message:
2021-04-29 11:41:56.955 CST,,"xxxxxdb01",183809,,608a2b04.2ce01,1,"",2021-04-29 11:41:56 CST,33/0,0,LOG,00000,"starting apply for subscription south89reportdb01",,,,,,,,,"pglogical apply 16387:4088059939"
2021-04-29 11:41:57.729 CST,,"xxxxxdb01",183809,,608a2b04.2ce01,2,"",2021-04-29 11:41:56 CST,33/0,0,ERROR,XX000,"data stream ended",,,,,,,,,"pglogical apply 16387:4088059939"
2021-04-29 11:41:57.729 CST,,"xxxxxdb01",183809,,608a2b04.2ce01,3,"",2021-04-29 11:41:56 CST,33/0,0,LOG,00000,"apply worker [183809] at slot 1 generation 915 exiting with error",,,,,,,,,"pglogical apply 16387:4088059939"
2021-04-29 11:41:57.730 CST,,,48250,,5fca5633.bc7a,980,,2020-12-04 23:30:59 CST,,0,LOG,00000,"worker process: pglogical apply 16387:4088059939 (PID 183809) exited with exit code 1",,,,,,,,,""
The error code XX000 in PostgreSQL means this is for "can't-happen" conditions and software bugs.
For now, when we create a subscription using pglogical.create_subscription(), there is no errors, however the status is down, and there pglogical apply process doesn't exist.
How can I dig this problem?
PostgreSQl 10.3 & pglogical 2.2.1
Hello! I had the same case. My steps to solve this problem
- Drop subscription.
- Drop all tables from replication_set (on host-provider)
- Recreate my subscription
- Add all tables that I need to replication_set again