turbot/aws_insights

Query: rds_db_cluster_logging_status

Usage

powerpipe query aws_insights.query.rds_db_cluster_logging_status

Steampipe Tables

SQL

select
logging_status,
count(*)
from (
select
case when (engine like any (array ['mariadb', '%mysql']) and enabled_cloudwatch_logs_exports ?& array ['audit','error','general','slowquery'] )or
( engine like any (array['%postgres%']) and enabled_cloudwatch_logs_exports ?& array ['postgresql','upgrade'] ) or
( engine like 'oracle%' and enabled_cloudwatch_logs_exports ?& array ['alert','audit', 'trace','listener'] ) or
( engine = 'sqlserver-ex' and enabled_cloudwatch_logs_exports ?& array ['error'] ) or
( engine like 'sqlserver%' and enabled_cloudwatch_logs_exports ?& array ['error','agent'] )
then 'enabled'
else
'disabled'
end logging_status
from
aws_rds_db_cluster) as t
group by
logging_status
order by
logging_status desc;

Dashboards

The query is used in the dashboards: