Skip to content

Latest commit

 

History

History
20 lines (12 loc) · 729 Bytes

master-slave.rst

File metadata and controls

20 lines (12 loc) · 729 Bytes

Master/slave

The shop can be operated with several databases. One database is the master database that mainly handles write accesses. Slave databases contain mirrored data and handle read accesses. Based on this fundamental distinction, database accesses are distributed to the master database and to the slave databases by a load balancer.

Configuration

Master/slave is enabled by making an entry in :file:`config.inc.php`.

$this->aSlaveHosts = null;

In this entry, all server addresses of the slave databases are specified as an array. The example uses two slave databases.

$this->aSlaveHosts = array('slave1host', '10.2.3.12');