跳至內容

Can we configure separate binary logging (binlog) on Aurora MySQL's Read Replica instance?

0

A customer has enabled binlog and expecting to get binlogs from read replica instance of Aurora - MySQL Cluster. Here are the steps being followed:

Enabled binlogs via cluster parameter group and set the format to ROW.

Restarted the cluster to ensure changes take effect

Logging into writer node shows

mysql> show master status -> ; +----------------------------+----------+--------------+------------------+-------------------+ | File | Position | Binlog_Do_DB | Binlog_Ignore_DB | Executed_Gtid_Set | +----------------------------+----------+--------------+------------------+-------------------+ | mysql-bin-changelog.000002 | 120 | | | | +----------------------------+----------+--------------+------------------+-------------------+ 1 row in set (0.01 sec)

However, the reader node does not return any value

mysql> show master status; Empty set (0.01 sec)

On both reader and writer, the bin_log_format is shown as ROW

MySQL [(none)]> SHOW VARIABLES LIKE 'binlog_format'; +---------------+-------+ | Variable_name | Value | +---------------+-------+ | binlog_format | ROW | +---------------+-------+ 1 row in set (0.061 sec)

Backup retention value is also set to a non-zero value.

My understanding here is you can pull binlog only from the writer node in Aurora. The replica nodes use redo logs and share the storage layer with the writer. The customer's expectations seems incorrect. Can I be doubly sure here?

AWS
專家

已提問 7 年前檢視次數 3646 次

2 個答案
0
已接受的答案

Yes, that is correct. You can only pull binary logs from the Writer Instance. Also, Amazon RDS normally purges a binary log as soon as possible, but the binary log must still be available on the instance to be accessed by mysqlbinlog. To specify the number of hours for RDS to retain binary logs, use the mysql.rds_set_configuration stored procedure and specify a period with enough time for for replication to occur.

How do I enable binary logging for Amazon Aurora for MySQL?: https://aws.amazon.com/premiumsupport/knowledge-center/enable-binary-logging-aurora/

AWS

已回答 7 年前

專家

已審閱 2 年前

0

This answer is 4 years old. Is this still the case now? We would like to read binlogs from Reader replica instead of Writer node for performance reasons.

已回答 3 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。