내용으로 건너뛰기

Can I retrieve binlogs from a MariaDB RDS snapshot

0

I want to rescue some binlogs from a snapshot of a MariaDB RDS instance.

However, when restoring from a snapshot I can see that the binlogs get deleted before the instance becomes connectable: Image showing BinLogDiskUsage metric fall sharply from >60G to 0

This is with a suitably long period set for automated backups.

Is there a way I can prevent the binlogs being deleted on start like this? Or is there some other way I can get at those bin logs?

질문됨 2년 전737회 조회

1개 답변
0

Hi

Here is the related question answered https://repost.aws/questions/QUF82SbQh6SUi5yT4Ito-BLw/why-don-t-i-get-en-event-with-binlog-information-when-i-create-a-snapshot

Binlogs info Link: https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/mysql-stored-proc-configuring.html

binlog retention hours
The binlog retention hours parameter is used to specify the number of hours to retain binary log files. Amazon RDS normally purges a binary log as soon as possible, but the binary log might still be required for replication with a MySQL database external to RDS.

The default value of binlog retention hours is NULL. For RDS for MySQL, NULL means binary logs aren't retained (0 hours).

To specify the number of hours to retain binary logs on a DB instance, use the mysql.rds_set_configuration stored procedure and specify a period with enough time for replication to occur, as shown in the following example.

call mysql.rds_set_configuration('binlog retention hours', 24);

Note
You can't use the value 0 for binlog retention hours.

For MySQL DB instances, the maximum binlog retention hours value is 168 (7 days).After you set the retention period, monitor storage usage for the DB instance to make sure that the retained binary logs don't take up too much storage.

Even if you set a binlog retention period, those** logs won't be captured in an RDS snapshot**. Snapshots are full backups at a specific point in time, excluding binlogs which track ongoing changes.

전문가

답변함 2년 전

전문가

검토됨 2년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

관련 콘텐츠