MariaDB Galera Cluster is a synchronous multi-master cluster for MariaDB. It is available on Linux only, and only supports the XtraDB/InnoDB storage engines (although there is experimental support for MyISAM - see the wsrep_replicate_myisam system variable).
Starting with MariaDB 10.1, the wsrep API for Galera Cluster is included by default. This is available as a separate download for MariaDB 10.0 and MariaDB 5.5.
MariaDB has one of the best and easiest solutions to do a Master-Master replication: Galera. Galera uses WSREP, which it is responsible for maintaining all the Database nodes in the cluster in sync. This means, after changing one record on node A, it is just a matter of seconds to see the change on node B.
I will talk in this article how I did this configuration using MariaDB 10.1.x. Remember you can install MariaDB under Centos 6 and 7 by using OKay's repository.