Using Console
Using CLI
<your-cluster-identifier>
with the identifier of your Redshift cluster, <your-S3-bucket-name>
with the name of the S3 bucket where you want to store the logs, and <prefix-for-logs>
with the prefix you want to use for the log files.Step 2: Verify that Audit Logging is EnabledloggingEnabled
parameter is set to true
.Step 3: (Optional) Set the Retention Period for Logs
You can also set the retention period for your logs using the following command:<number-of-days>
with the desired retention period for your log files.By following these steps, you can successfully remediate the misconfiguration of Redshift Cluster Audit not having logging enabled in AWS using AWS CLI.Using Python
'your-redshift-cluster-identifier'
with the actual identifier of your Redshift cluster and 'your-s3-bucket-name'
with the name of the S3 bucket where you want to store the logs.