1

I want to implement highly safe system storage with mysql.

My case is:

  1. I need to store records.
  2. For more safety i want to have N separate physical mysql nodes.
  3. Then client save record and get OK response at this moment I want to be sure that data durable written in all N nodes.

Can mysql cover this? I am not familiar with mysql replication can it cover this?

  1. Then client save key value and get OK response - at this moment I want to be sure that data durable written in all N nodes.

So I am afraid that then client get "ok" on saving row in mysql the data can be written in one node (other replicas not sync) and if at this moment crash happens in only one node that holds client row i can't restore it (replicas not in sync).

So i want be sure that all nodes written then client get OK.

Should i use mysql replication or I must implement this on applicaion level by do N separate INSERTS to N servers or something other?

2

The simple answer - You need Galera or NDB cluster

This is very simple form of answer, because new problems could come after this.

Some often "next" questions from projects - all was fine on my old server, but now my UPDATE of 5000000 records - always fail!

Or - I have 3 nodes, but my insert start work much slower, help me please! I just every few minutes run SELECT GROUP BY over 500 000 rows - but it was perfect work before.

If high safety - it mandatory, cluster + replication (or any other solution for reporting part of application - such as AWS Redshift and etc) - http://severalnines.com/blog/how-set-asynchronous-replication-galera-cluster-standalone-mysql-server-gtid

The best way - install and test!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.