WordPress HyperDB

HyperDB is a WordPress plugin that allows you to use multiple MySQL database servers with large MySQL installations. It is used to WordPress.com to distribute MySQL server load amount multiple MYSQL database servers hosted in different data centers.

HyperDB supports

  • Read and write servers (replication)
  • Configurable priority for reading and writing
  • Local and remote datacenters
  • Private and public networks
  • Different tables on different databases/hosts
  • Smart post-write master reads
  • Failover for downed host
  • Advanced statistics for profiling
  • WordPress Multisite

You can find more about the HyperDB plugin at

https://wordpress.org/plugins/hyperdb/

How it works

HyperDB replaces WordPress wpdb class so it can read from multiple MySQL database servers.

On a default WordPress installation, when a website grows, you need to upgrade the server to a more powerful server, but there is a limit on this as at some point upgrading server becomes costly. What you can do is move MySQL into its own dedicate server. For larger WordPress sites, a single dedicated MySQL server is not enough. In such a case, you can set up MySQL replication. When you set up MySQL replication with read-only nodes, you can only write to “main” MySQL server, all Database reads can be distributed across multiple MySQL read-only replicas. HyperDB checks each MySQL query, detect if it is a read or write/update query. If read, it is sent to one of the read-only MySQL replica servers.

See WordPress

Leave a Reply

Your email address will not be published. Required fields are marked *