com.amazonaws.services.s3.model.AmazonS3Exception: Forbidden (Service: Amazon S3; Status Code: 403; Error Code: 403 Forbidden; Request ID: 409F9DDD8763ADE7)

tip

Set the S3 bucket to the same region as AmazonS3Client, otherwise it just throws this exception. Check if your bucket name is correct as well.

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • Hadoop S3 List Bucket Contents Error
    via Stack Overflow by prometheus2305
    ,
  • Using Riak CS with Hadoop
    via by Valenti, Anthony,
    • com.amazonaws.services.s3.model.AmazonS3Exception: Forbidden (Service: Amazon S3; Status Code: 403; Error Code: 403 Forbidden; Request ID: 409F9DDD8763ADE7) at com.amazonaws.http.AmazonHttpClient.handleErrorResponse(AmazonHttpClient.java:1182) at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:770) at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:489) at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:310) at com.amazonaws.services.s3.AmazonS3Client.invoke(AmazonS3Client.java:3785) at com.amazonaws.services.s3.AmazonS3Client.getObjectMetadata(AmazonS3Client.java:1050) at com.amazonaws.services.s3.AmazonS3Client.getObjectMetadata(AmazonS3Client.java:1027) at org.apache.hadoop.fs.s3a.S3AFileSystem.getFileStatus(S3AFileSystem.java:1025) at org.apache.hadoop.fs.s3a.S3AFileSystem.getFileStatus(S3AFileSystem.java:82) at org.apache.hadoop.fs.FileSystem.exists(FileSystem.java:1432) at org.apache.hadoop.fs.s3a.S3AFileSystem.create(S3AFileSystem.java:514) at org.apache.hadoop.fs.FileSystem.create(FileSystem.java:921) at org.apache.hadoop.fs.FileSystem.create(FileSystem.java:902) at org.apache.hadoop.fs.contract.ContractTestUtils.writeDataset(ContractTestUtils.java:141) at org.apache.hadoop.fs.s3a.TestS3AEncryptionAlgorithmPropagation.writeThenReadFile(TestS3AEncryptionAlgorithmPropagation.java:87) at org.apache.hadoop.fs.s3a.TestS3AEncryptionAlgorithmPropagation.testEncrypt256(TestS3AEncryptionAlgorithmPropagation.java:69)

    Users with the same issue

    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    tvrmsmith
    tvrmsmith2 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    49 more bugmates