Blog of Raivo Laanemets

AWS CLI S3 listing error


AWS CLI installed on Ubuntu 14.04 LTS from system package gives an error when listing the bucket contents by using a command like aws s3 ls s3://bucket. The error message is the following:

A client error (AccessDenied) occurred when calling
the ListObjects operation: Access Denied

Googling for the error message leads to various solutions by adding custom IAM policies. I tried some of them but nothing helped.

I got it fixed by installing aws-cli using pip (actually a recommended approach by AWS), not by using apt-get. It might be that the system-packaged version is too old and incompatible with the recent AWS API. Still, the error message could be a bit less misleading.


No comments have been added so far.

Email is not displayed anywhere.
URLs (max 3) starting with http:// or https:// can be used. Use @Name to mention someone.