uwe
uwe

Reputation: 4077

Is there a simple way to report on Amazon S3 404 errors?

How can I setup a simple 404 reporting for a Amazon S3 bucket?

Upvotes: 4

Views: 2802

Answers (1)

cdeszaq
cdeszaq

Reputation: 31280

Turning on Server Access Logging for your S3 buckets will give you the information you are after. It will not only give you the successful requests made to the logged bucket, but will also give the requests which resulted in errors.

The logs are space-delimited text files, so they should be very easy for you to parse. Virtually all flavors of Linux should have the needed tools to:

  1. Pull down the zipped log file
  2. Un-pack the file
  3. Grep the file for 404 errors
  4. Send that list of files to another file

Putting this process into a cron job to run daily is a simple automation that will allow you to gather this data as you need to, and can easily be extended with more functionality using any modern programming package.

If you are looking for something "more simple" than this, I am sure there are a number of individuals and companies that would be more than happy to develop a simple application to do this for you. For a small fee, of course ;)

Upvotes: 5

Related Questions