mercredi 25 mars 2015

Amazon rds read-replica, use as archive database


I have hosted my database (MySql) on Amazon RDS service and also created read-replica in the same availability zone. I have send my read queries on that read-replica. Now a days my database is become a very huge with data (about 10gb) and growing on. So I have decided to remove old data from master, but not from read-replica. Is it possible? somewhere I have read that "sql_log_bin" set off while removing old records from master, (so, it can't be replication on slave/read-replica), but when I have tried, it can't worked. Can someone show me how to archive old data from master to other database, and How to handle foreign key on master?


In my case, many old records has relation with currently using records. So How do I handle this kind of situation?





Aucun commentaire:

Enregistrer un commentaire