maria-discuss team mailing list archive
Mailing list archive
Re: Are lock/unlock tables replicated in ROW / STATEMENT / MIXED r. mode
Am 13.01.2016 um 15:35 schrieb pslawek83:
Hi Guys, quick question about lock tables with replication...
I basically use it to achieve atomicity of some database writes, but it seems that queries like
LOCK TABLES ___tsc WRITE
are not replicated to slave.
Eg. i can lock table on master, for write, but still read from it on the slave, which could lead to issues...
We're reading some data from slaves, and writing data to it atomically using LOCK TABLES, it seems that this way will lead to race conditions and inconsistent reads from the slave. Any way of having aria/myisam writes to be atomic on the slaves too? I thought to copy the table to random temporary name, do the changes and then rename... but it seems like not very optimal.
that's why InnoDB and transactions exists
use the right tool for the job
Description: OpenPGP digital signature