跳到主要内容

Using Deskpro With Galera Cluster - 知识库 / Deskpro Legacy - Deskpro Support

WARNING: You're browsing documentation for an older version of Deskpro. Consider upgrading to Deskpro Horizon

Using Deskpro With Galera Cluster

作者列表

Galera is a synchronous multi-master technology for MySQL. Galera is used by Percona XtraDB Cluster and also by MariaDB Cluster, so if you use either of those products, this article pertains to you as well.

Deskpro does not support true multi-master configurations at this time. There are problems to do with concurrent writes and non-sequential IDs that need to be addressed (and we are actively working on it).

However, you can still use Galera with Deskpro. Indeed, we highly recommend Galera for an easy way to achieve high availability.

 

Using Galera with a single master

The idea is to use Galera for reliable replication and node management, but use it in a traditional master-slave way. That is, Galera itself is capable of multi-master writes, but you won't be using multiple masters with Deskpro.

1) Disable auto-increment control

In my.cnf you need to disable auto-increment controls:

innodb_autoinc_lock_mode=1
wsrep_auto_increment_control=OFF

By default, Galera will add "gaps" in auto-increment columns. This prevents collisions when concurrent inserts happen on multiple hosts. But since we aren't going to use multiple nodes for writes, we need to disable this option.

 

2) Deskpro should use a single master

You need to make sure Deskpro is only ever using a single master at a time. If you are using Galera, it is common practice to load-balance connections between all masters. But again, we aren't using multiple nodes, so you must route all connections to a single master.

(That said, we still recommend using a load balancer so connections can be automatically routed to a new master in the event your primary master goes offline.)

 

3) Optionally route read-only queries to other nodes

Since you have multiple nodes, you might as well use them to perform some of the more intensive read queries that Deskpro performs regularly. See our article Configuring read-only database for expensive queries.

有帮助 没有帮助

117 人中 58 人认为这个页面有帮助

添加一条评论

请登录或注册以提交评论。

是否需要密码提醒?