Troubleshooting errors when working with Amazon S3

When you use Hue with Amazon S3, you might encounter these errors. To view buckets, directories, and files that have been added to your S3 account, restart the Hue service.

Error Message Example Possible Solution
Failed to access path:
Failed to access path: "s3a://quakes".
Check that you have access to read this bucket and that
the region is correct.
Check your bucket region:
  1. Log on to your AWS account and navigate to the S3 service.
  2. Select your bucket, for example "quakes", and click Properties.
  3. Find your region. If it says US Standard, then region=us-east-1.
  4. Update your configuration in Hue Service Advanced Configuration Snippet (Safety Valve) for hue_safety_valve.ini.
  5. Save your changes and restart Hue.
The table could not be created.
The table could not be created. Error while compiling statement:
FAILED: SemanticException com.cloudera.com.amazonaws.AmazonClientException:
Unable to load AWS credentials from any provider in the chain.
Set your S3 credentials in Hive core-site.xml:
  1. In Cloudera Manager, go to Hive > Configuration.
  2. Filter by Category > Advanced.
  3. Set your credentials in Hive Service Advanced Configuration Snippet (Safety Valve) for core-site.xml.
    1. Click the button and input Name and Value for fs.s3a.AccessKeyId.
    2. Click the button and input Name and Value for fs.s3a.SecretAccessKey.
  4. Save your changes and restart Hive.
The target path is a directory. - Remove any directories or files that may have been added to s3a://quakes/input/ (so that all_month.csv is alone).
Bad status for request TFetchResultsReq … Not a file
Bad status for request TFetchResultsReq(...): TFetchResultsResp
(status=TStatus(errorCode=0, errorMessage='java.io.IOException:
java.io.IOException: Not a file: s3a://Not a file: s3a://quakes/input/output' ...

Remove any directories or files that may have been added to s3a://quakes/input/ (so that all_month.csv is alone). Here, Hive cannot successfully query the earthquakes table (based on all_month.csv) due to the directory, s3a://quakes/input/output.