We clone the data from a standby server(S1) in which data replicated from a active master(M) by doing stop slave in standby(S1) to create new standby server(S2) like M --> S1 —> S2
The data will be consistent in this approach but while starting the S2 it goes to INNODB crash recovery & takes long time to start.
Data size will be approx 300 GB that spans across 150 database with approx 1.5 Million tables
How to Overcome this ?
We do the following steps.,
Stop slave S1
Flush logs S1
Mark the positions (bin log file)
Unzip mysql kit in s2
rsync ibdata iblog* & data/* files to S2 from S1
And start the server in S2