How do I publish logs for Amazon RDS or Aurora for MySQL instances to CloudWatch?
I have an Amazon Relational Database Service (Amazon RDS) or Amazon Aurora instance that's running MySQL. How can I view the DB logs for my instance in Amazon CloudWatch?
"I have an Amazon Relational Database Service (Amazon RDS) or Amazon Aurora instance that's running MySQL. How can I view the DB logs for my instance in Amazon CloudWatch?Short descriptionTo view Amazon RDS logs in CloudWatch, first allow logging on the DB instance or cluster. Then, you can configure log exports on the DB instance to send the logs to CloudWatch.ResolutionAllow logging on your DB instanceFor Amazon RDS instances that run MySQL, modify the parameters for the  general_log and slow_query_log in a custom DB parameter group that's associated with the DB instance. To allow audit logging, add the MariaDB Audit Plugin to your custom option group. For more information, see How do I activate and monitor logs for an Amazon RDS for MySQL instance?For Aurora clusters that run MySQL, modify the paramters for the general_log and slow_query_log. Allow Advanced Auditing to audit the logs for your Aurora clusters by using a custom cluster parameter group.Publish logs to CloudWatchTo publish logs to CloudWatch, configure log exports on the DB instance and then set the log_output parameter to FILE. For Aurora, any selected log types are published for all instances of an Aurora DB cluster.Configure log exportsOpen the Amazon RDS console.Choose Databases from the navigation pane.Select the instance that you want to publish logs to CloudWatch for, and then choose Modify.From the Log exports section, select the log types that you want to publish.Choose Continue, and then choose Modify DB Instance.Note: This modification doesn't require downtime.Change the value of the log_output parameterNote: This step isn't required for Aurora clusters that run MySQL 5.7 unless the value of the log_output parameter was manually modified to TABLE. For Aurora clusters that run MySQL 5.7, the default value of the log_output parameter is FILE.Open the Amazon RDS console.Choose Parameter groups from the navigation pane.Select the parameter group that's associated with the instance that you want to publish logs for.Choose Parameter group actions, and then choose Edit.Use the Filter parameters field to search for the log_output parameter.Set the value of the log_output parameter to FILE.Choose Save changes.Note: This is a dynamic parameter, so this modification doesn't require a restart. For more information, see Working with parameter groups.Related informationHow do I modify the values of an Amazon RDS DB parameter group?MySQL database log filesPublishing Amazon Aurora MySQL logs to Amazon CloudWatch logsFollow"