Custom Search

Tuesday, July 23, 2013

Howto boto vm-import-export@amazon.com WRITE READ_ACL permission S3 bucket

Error
=====
Client.AuthFailure: vm-import-export@amazon.com must have WRITE and READ_ACL permission on the S3 bucket

Solution
=======
import boto
from pprint import pprint

conn = boto.connect_s3(aws_access_key_id="xxxxxxxx", aws_secret_access_key="xxxxxxxxx")

b = conn.get_bucket("my-bucket")

b.add_email_grant("READ_ACP", "vm-import-export@amazon.com")
b.add_email_grant("WRITE", "vm-import-export@amazon.com")

grants = b.list_grants()

for gr in grants:
    print "=====gr======", pprint(vars(gr))

6 comments:

  1. http://docs.aws.amazon.com/AWSRubySDK/latest/AWS/EC2/Instance.html
    https://forums.aws.amazon.com/thread.jspa?threadID=99336

    ReplyDelete
  2. where i can apply this code? is this python?

    thanks in advance!

    ReplyDelete
  3. I am also getting this error.

    An error occurred (AuthFailure) when calling the CreateInstanceExportTask operation: vm-import-export@amazon.com must have WRITE and READ_ACL permission on the S3 bucket.


    Please suggest. also executed provide py script using lambda function which thrown syntex error.

    ReplyDelete
  4. Hello, did you find a solution to the error? I have the same

    ReplyDelete