Keith Fiske wrote: [dd] > > You cannot run the actual scan on the replica, no. But it can be set to run > against the replica and just report the statistics so you can have a cron > set up to always run on the given system in case of failover. The > "--recovery_mode_norun" can be set so it will only run if the target system > is actually a primary. > > I could possibly see about letting this actually run against the replica, > however this can be a rather long running transaction depending on the size > of the tables involved. You can set the "--commit_rate" to avoid some of > that, but if you have really large tables, it can still run quite long. So > this sort of check is really best run against the primary to avoid issues > around having to allow long running queries on the replica (delayed > replication or even worse bloat buildup). If you have a dedicated replica for OLAP, even one running from a WAL archive (not from a replication slot), this is not an issue. So running pg_bloat_check against a replica would be very useful for some of us. -- Victor Sudakov, VAS4-RIPE, VAS47-RIPN 2:5005/49@fidonet http://vas.tomsk.ru/