we got a similar issue.
We install 2 revive (5.2.0) in master-slave config:
OS: Ubuntu 18.04
NGINX : nginx/1.21.0
MYSQL: 5.7.34 (community)
The master get his consolidation and works fine.
The Slave (Delivery Server).
Already configured de lb database in domain.conf.php pointing to master.
but in the minute that run's de revive/scripts/maintenance/maintenance-distributed.php we get the next error.
May 27 13:24:28 -0300 OX-60afc7bcbcb56 [emergency] -111 :: MDB2_Error Object