Explore these AWS CloudTrail MCQ questions and answers to strengthen your knowledge of trail configuration and management. This collection covers creating and managing trails, integration with S3 and CloudWatch Logs, and multi-region and multi-account trails. Ideal for cloud professionals, these questions ensure you’re prepared for AWS monitoring and auditing challenges.
MCQs
Creating and Managing Trails
What is the primary purpose of AWS CloudTrail? a) To track API requests made to AWS services b) To monitor instance health c) To manage storage encryption d) To create IAM roles
What is a trail in AWS CloudTrail? a) A log of API activity b) A feature to monitor CPU usage c) A tool for analyzing security groups d) A CLI command
How many trails can you create per region in an AWS account? a) 5 b) 10 c) 3 d) Unlimited
Which of the following is required to enable CloudTrail logging? a) A trail b) An EC2 instance c) An IAM group d) A NAT gateway
What is the default retention period for CloudTrail event logs? a) 90 days b) 365 days c) 30 days d) 7 days
Which type of events can CloudTrail capture? a) Management events and data events b) Instance health events c) Network traffic logs d) Lambda execution logs
What is the purpose of enabling log file validation in CloudTrail? a) To verify that log files are not tampered with b) To compress log files c) To store log files in multiple regions d) To encrypt log files
How do you delete a trail in AWS CloudTrail? a) Using the AWS Management Console or AWS CLI b) By stopping the trail first c) By terminating associated EC2 instances d) By deleting IAM roles
Integration with S3 and CloudWatch Logs
Where does AWS CloudTrail store its logs by default? a) Amazon S3 b) AWS Glue c) CloudWatch Logs d) Amazon Redshift
Which permission is required for CloudTrail to write logs to an S3 bucket? a) s3:PutObject b) s3:GetObject c) cloudtrail:WriteLogs d) iam:PassRole
How can you monitor CloudTrail logs in real time? a) Integrate CloudTrail with CloudWatch Logs b) Use AWS Glue for ETL processes c) Query logs in S3 directly d) Run scripts on EC2 instances
Which policy should you attach to an S3 bucket for CloudTrail log storage? a) Bucket policy allowing CloudTrail service principal access b) A policy granting EC2 instance access c) IAM role for S3 full access d) KMS key policy
How do you enable log file encryption for CloudTrail? a) By configuring a KMS key in the trail settings b) By creating an encrypted S3 bucket c) By using EC2 instance metadata d) By enabling VPC flow logs
What is a common use case for integrating CloudTrail logs with CloudWatch? a) Real-time alerts on specific API calls b) Improved storage performance c) Enhanced encryption capabilities d) Dynamic IAM role creation
What CloudTrail setting is needed to log events across all AWS regions? a) Enable multi-region trail b) Configure IAM cross-account roles c) Use VPC endpoint for logging d) Turn on global IAM role replication
Multi-Region and Multi-Account Trails
What is the benefit of creating a multi-region trail? a) It captures events from all AWS regions in a single trail b) It enables automatic resource tagging c) It improves EC2 instance performance d) It synchronizes S3 bucket contents
Can you configure a single CloudTrail trail for multiple AWS accounts? a) Yes, using AWS Organizations b) No, each account must have its own trail c) Only if the accounts share the same region d) Only for EC2-specific events
How do you manage CloudTrail logs for a multi-account setup? a) Use an organization trail b) Create separate trails for each account c) Enable CloudWatch cross-account access d) Configure individual IAM roles
What happens when a multi-region trail is created? a) All API events from all regions are recorded in the trail b) Only data events are recorded c) The trail automatically encrypts all events d) The trail stores logs in Amazon Redshift
How can you restrict access to CloudTrail logs stored in S3? a) By using bucket policies and IAM roles b) By enabling default encryption c) By configuring VPC endpoints d) By setting up EC2 instance metadata
What feature allows an AWS administrator to track activity across all accounts in an organization? a) Organization trails b) IAM groups c) CloudWatch events d) AWS Config
How can you validate the integrity of multi-account CloudTrail logs? a) Enable log file validation b) Use VPC flow logs c) Query logs with Athena d) Monitor with GuardDuty
What is required for a cross-account CloudTrail trail to store logs? a) A bucket policy that grants the CloudTrail service access b) An IAM role in each account c) An EC2 instance with write permissions d) A dedicated KMS key
Which tool is commonly used to analyze CloudTrail logs? a) AWS Athena b) Amazon S3 Select c) AWS Glue d) Lambda
How can you optimize costs for a multi-region CloudTrail setup? a) Store logs in a single S3 bucket with lifecycle policies b) Enable detailed monitoring in CloudWatch c) Compress logs using EC2 instances d) Reduce the number of enabled regions
Answer Key
Qno
Answer
1
a) To track API requests made to AWS services
2
a) A log of API activity
3
b) 10
4
a) A trail
5
a) 90 days
6
a) Management events and data events
7
a) To verify that log files are not tampered with
8
a) Using the AWS Management Console or AWS CLI
9
a) Amazon S3
10
a) s3:PutObject
11
a) Integrate CloudTrail with CloudWatch Logs
12
a) Bucket policy allowing CloudTrail service principal access
13
a) By configuring a KMS key in the trail settings
14
a) Real-time alerts on specific API calls
15
a) Enable multi-region trail
16
a) It captures events from all AWS regions in a single trail
17
a) Yes, using AWS Organizations
18
a) Use an organization trail
19
a) All API events from all regions are recorded in the trail
20
a) By using bucket policies and IAM roles
21
a) Organization trails
22
a) Enable log file validation
23
a) A bucket policy that grants the CloudTrail service access
24
a) AWS Athena
25
a) Store logs in a single S3 bucket with lifecycle policies