Showing entries 1 to 10 of 1023
10 Older Entries »
Displaying posts with tag: Replication (reset)
Security Configuration For MySQL NDB Cluster Replication

In this blog, we will discuss about how to setup MySQL NDB Cluster replication in a more secure way with the help of binary log and relay log encryption and a secure connection. These measures protect binary log dat in transit and at rest.

Let’s create two MySQL NDB Clusters with the following environment, Here, one will be termed as ‘source’ cluster and the other one will be termed as ‘replica’ cluster.

  • MySQL NDB Cluster version (Latest GA version)
  • 1 Management node
  • 4 Data nodes
  • 1 MySQLDs
  • Configuration slots for up to 4 additional API nodes

Step 1: Start both of the Clusters

Let’s start both the source cluster and replica cluster but do not start the MySQLD servers from both the clusters as we want to modify their configuration first.

[Read more]
MySQL NDB Cluster Replication Topologies (Part – IV)

In this blog, we will discuss, how to setup MySQL NDB Cluster replication through backup and restore method. This is bit tricky but interesting. The scenario here is, say user have a standalone cluster up and running, later there is a need to have a replication setup with an another empty cluster without shutting down the existing running cluster i.e. zero downtime. Then this backup and restore method will come in handy.

Let’s create two MySQL NDB Cluster with the following environment, Here, one will be termed as ‘source’ cluster and the other one will be termed as ‘replica’ cluster.

  • MySQL NDB Cluster version (Latest GA version)
  • 1 Management Node
  • 4 Data Nodes
  • 1 MySQLDs
  • Configuration slots for up to 4 additional API nodes

Replication schema diagram:
CLUSTER 'A'        …

[Read more]
MySQL NDB Cluster Replication Topologies (Part – III)

In this blog, we will discuss about bidirectional replication between two NDB clusters. With this topology, user can do transaction simultaneously from both the clusters on the same database objects.

Let’s create two MySQL NDB Cluster with the following environment, Here, both will be termed as ‘source’ cluster as well as ‘replica’ cluster as we will do replication from both the sides.

  • MySQL NDB Cluster version (Latest GA version)
  • 1 Management node
  • 4 Data nodes
  • 2 MySQLDs
  • Configuration slots for up to 4 additional API nodes

Replication schema diagram:

                    |-----------S1---------->>----------S3--------------|                   …

[Read more]
MySQL NDB Cluster Replication Topologies (Part – II)

In the previous blog, we were able to setup a MySQL NDB Cluster replication between one source and one replica cluster. In this blog, we will discuss about replication between one source and three replica clusters.

Note: With MySQL version (8.0.21), we have started changing the term “master” to “source”, the term “slave” to “replica”. So in this blog we will refer these terms ‘source’ and ‘replica’ wherever applicable.

The main advantage of this type of topology is good for giving ‘local’ reads in geographically distant areas as well as increased redundancy in case of issues.

Let’s create four MySQL NDB Cluster with the following environment, from which one will be termed as ‘source’ cluster while the rest will be ‘replica’ clusters.

  • MySQL NDB Cluster version (Latest GA version)
  • 1 Management node
  • 4 Data nodes …
[Read more]
MySQL NDB Cluster Replication Topologies (Part – I)

In this blog series, we will discuss various MySQL NDB Cluster replication topologies possible with a demonstration. We will start with a simple case i.e. one source (formerly called master) and one replica (formerly called slave).

Note: With MySQL version (8.0.21), we have started changing the term “master” to “source”, the term “slave” to “replica”. So in this blog we will refer these terms ‘source’ and ‘replica’ wherever applicable.

Let’s create two MySQL NDB Cluster with the following environment, from which one will be termed as ‘source’ cluster while the other one will be ‘replica’ cluster. For now, let’s stick to the identical environment from both the cluster. Later in the following blog series, we will change the environments and will run the replication.

  • MySQL NDB Cluster version (Latest GA version)
  • 1 Management node
  • 4 Data nodes …
[Read more]
Setup DR for your MySQL InnoDB Cluster

MySQL InnoDB Cluster is the High Availability solution for MySQL. It delivers automatic fail-over and guarantees zero data loss (RPO=0).

RPO: Recovery Point Objective describes the interval of time that might pass during a disruption before the quantity of data lost during that period exceeds the Business Continuity Plan’s maximum allowable tolerance.

Example: our business architecture needs to have RPO=2 minutes. This means that in case of failure, 2 minutes of data can be lost.

However, and we saw this recently in Europe, an entire data center can “disappear” instantaneously… So it’s also important to have a Disaster Recovery plan.

One solution, is to have an InnoDB Cluster (Group Replication) that spans across multiple regions. However, this is often not feasible because of high latency across regions.

Another solution is InnoDB Cluster in one region with Asynchronous …

[Read more]
Fastest Parallel replication method in MySQL 8.

From MySQL 5.7, we had a Multi-threaded Slave (MTS) Applier mechanism called LOGICAL_CLOCK to overcome the problems of parallel replication within a database.

To further improve the parallelisation mechanism, from MySQL 8 (5.7.22) we have write-set replication, so before going further , lets look at the difference between Logical clock (LC) and Writeset.

LOGICAL_CLOCK

Transactions that are part of the same binary log group commit on a master are applied in parallel on a slave. The dependencies between transactions are tracked based on their timestamps to provide additional parallelisation where possible.

WRITESET

Write-set is a mechanism to track independent transactions that can be executed in parallel in the slave. Parallelising on write sets has potentially much more parallelism than logical_clock ,since it does not depend …

[Read more]
Replicate from MySQL 5.7 to MySQL Database Service

MySQL Replication is a very common topology, widely used in various architecture.
People use it, among others, for High Availability, Read Scalability or Geographic Redundancy.

Another use case is to use MySQL Replication to seamlessly integrate a newer version of the server in your architecture.
Let’s say you are running MySQL 5.7 then you can easily setup a 8.0 instance as a replica of your 5.7.

Extending this idea it is also possible to replicate your MySQL 5.7 (or 8.0 obviously) to a MySQL Database Service instance, the true MySQL PaaS on Oracle Cloud Infrastructure.

The post Replicate from MySQL 5.7 to MySQL Database Service first appeared on dasini.net - Diary of a MySQL experts.

MySQL per channel replication filters examples

This is a simple article with an examples for “how to configure replication filters for channel”

Starting from MySQL 8.0 replication filters can be global or channel-specific, enabling you to configure multi-source replicas with replication filters on specific replication channels. Channel specific replication filters are particularly useful in a multi-source replication topology when the identical database or table is present on multiple sources, and the replica is only required to replicate it from one source.

Example:

CHANGE REPLICATION FILTER REPLICATE_DO_DB =(test,test3,test4 ), REPLICATE_REWRITE_DB = ((test1,test3),(test2,test4)) FOR CHANNEL "node1";

my.cnf confiration to make replication filter setting persistent:

replicate-do-db=node1:test
replicate-do-db=node1:test3
replicate-do-db=node1:test4
replicate-rewrite-db=node1:test1->test3 …
[Read more]
MySQL Cluster Backup and Restore

MySQL Ndb Cluster provides durability for data by default via logging and checkpointing.

In addition, users can take backups at any time, which allows for disaster recovery, replication synchronisation, data portability and other use cases.

This post looks at the backup and restore mechanisms in MySQL Ndb Cluster.

MySQL Ndb Cluster architecture recap

MySQL Ndb Cluster is a distributed SQL relational database :

  • Designed for low overhead read + write scale out, high availability, high throughput and low latency.
  • Providing distributed parallel joins, transactions, row locks, foreign keys.
  • Data is primarily stored and managed by a set of independent data node processes.
  • Data is accessed via distributed MySQL servers and …
[Read more]
Showing entries 1 to 10 of 1023
10 Older Entries »