Loading topic
psql, and can edit postgresql.conf. It explains how PostgreSQL turns the WAL, a record of physical page changes, into a stream of row-level inserts, updates, and deletes that a subscriber can apply. Later chapters build on 6 min readCREATE PUBLICATION or CREATE SUBSCRIPTION. Most failed first setups trace back to one of these three. This chapter walks through each one and shows how to check it.6 min readpsql, edit postgresql.conf, and create tables with primary keys. It also assumes you know that wal_level = logical is already set on the publisher and that a replication role exists. Earlier chapters covered both. Here the focus is the object that decides what 6 min readpsql, edit postgresql.conf, and read a basic SELECT against system views. It also assumes you know that the write-ahead log (WAL) is the sequential record of every change the server makes. You should already have a publication on the publisher and know what a s5 min readpsql as a superuser, that the publisher has wal_level = logical, and that a publication such as orders_pub already exists. It also assumes the publisher accepts connections from the subscriber (pg_hba.conf) and that a role with the REPLICATION attribute and6 min readCREATE SUBSCRIPTION and the moment the subscriber starts applying live changes. It assumes you have already created a publication and a subscription, understand replication slots and WAL retention, and can read pg_stat_* views in psql.6 min readpsql, and know that a publication sends row changes from a publisher to a subscriber. It also assumes you know that a subscription applies those changes to its own copy of the table.6 min readpublish option works in older versions.5 min readCREATE, ALTER, DROP) safely, and which errors to expect when the two sides drift apart.7 min read