S3 bucket keeps having log files added

0

I don't know why, but I keep trying to empty a bucket and it keeps creating more log files. Does anyone know how to stop this? I haven't used this bucket in years and just want to delete it, but need to empty it first. They're formatted as: log_2023-09-03-23-12-34-BFB4EDE6B444B339 and are being created every few seconds.

asked 8 months ago256 views
2 Answers
0
Accepted Answer

Hello.

It is probably an S3 bucket created for S3 server access logs.
Try deactivating the S3 server access log or remove the bucket policy and change it so that the access log cannot be output.
https://docs.aws.amazon.com/AmazonS3/latest/userguide/ServerLogs.html

profile picture
EXPERT
answered 8 months ago
profile picture
EXPERT
reviewed 8 months ago
profile pictureAWS
EXPERT
reviewed 8 months ago
profile pictureAWS
EXPERT
reviewed 8 months ago
0

Hi,

You might have enabled logging for the S3 bucket, and each of your operations with S3 objects is logged. So, basically, when you delete log_2023-09-03-23-12-34-BFB4EDE6B444B339 file, you have another one with the record that the file has been deleted.

You need to disable S3 server access logging, then empty the bucket and finally delete it.

profile picture
EXPERT
answered 8 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions