CloudSQL HA binary log retention

30 views
Skip to first unread message

Zhivko Angelov

unread,
Nov 9, 2020, 12:44:24 PM11/9/20
to Google Cloud SQL discuss

I am running CloudSQL with HA enabled and one read replica. Recently I notices that the used space of the primary instance is larger than the read replica (more than 10%). It turned out that there is a lot of binary logs (68 files). I have also noticed that the expire_logs_days is set to 0 which means that there is no automatic removal. How am I supposed to manage the retention of the binary logs ?

Manpreet Sidhu (Google Cloud Support)

unread,
Nov 9, 2020, 9:22:51 PM11/9/20
to Google Cloud SQL discuss
Hi!

There are 2 kinds of backups, Manual and Automatic. They both save a binlog.

If you have Automatic backups, they are kept for 7 days and the binlog is deleted automatically with the backup after 7 days.

If you have manual backups, the binlogs and backups will not be deleted.

It is suggested to use automated backups as Cloud SQL will manage your backups and deletes. This has been confirmed with the engineering team[1].

Reply all
Reply to author
Forward
0 new messages