HiveBrain v1.2.0
Get Started
← Back to all entries
patternsqlMinor

enabling BINARY LOG on AWS RDS MySQL

Submitted by: @import:stackexchange-dba··
0
Viewed 0 times
logmysqlbinaryawsrdsenabling

Problem

Context

I am trying to enable BINARY LOGs on a MySQL RDS instance.

Issue

I used CALL mysql.rds_set_configuration('binlog retention hours', 24) without encountering an error.

And using CALL mysql.rds_show_configuration says "binlog retention hours" value is 24

But SHOW BINARY LOGS says "#1381 - You are not using binary logging"

Am I missing something ?

Additional information :

  • using SHOW GRANTS results in GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP...



  • I tried rebooting the instance. It didn't work.



  • automatic backups are enabled with a 1 day retention



useful documents

  • Using a Amazon-Managed MySQL-Compatible Database as a Source for AWS DMS



  • AmazonRDS/latest/UserGuide/mysql_rds_set_configuration

Solution

Amazon will not allow the user to enable binlogs.

You have to enable automatic backups on the RDS Instance. The RDS framework will then enable binary logs for you. You cannot enable them manually. Please see this post in the AWS forums (which states the reverse, setting backup retention to 0 disables binary logging).

The default backup retention is 7 days. I recommend setting

mysql> CALL mysql.rds_set_configuration('binlog retention hours', 168)


so as to match the back retention

Code Snippets

mysql> CALL mysql.rds_set_configuration('binlog retention hours', 168)

Context

StackExchange Database Administrators Q#216809, answer score: 6

Revisions (0)

No revisions yet.