2017-04-21 9 views
2

S3バケットでAmazon Athenaのクエリを実行しているときに、以下のエラーが表示されます。Amazon Athena - S3の位置エラー

CloudFrontアクセスログでこのクエリを実行しています。

CREATE EXTERNAL TABLE IF NOT EXISTS cloudfront.cf_logs (
    `date` date, 
    `time` string, 
    `location` string, 
    `bytes` int, 
    `requestip` string, 
    `method` string, 
    `host` string, 
    `uri` string, 
    `status` int, 
    `referrer` string, 
    `os` string, 
    `browser` string, 
    `browserversion` string 
) 
ROW FORMAT SERDE 'org.openx.data.jsonserde.JsonSerDe' 
WITH SERDEPROPERTIES (
    'serialization.format' = '1' 
) LOCATION 's3://cloudfront-access/test-sh/' 
TBLPROPERTIES ('has_encrypted_data'='false'); 

エラーが返さ:

Your query has the following error(s): 

The S3 location provided to save your query results is invalid. Please 
check your S3 location is correct and is in the same region and try 
again. If you continue to see the issue, contact customer support for 
further assistance. (Service: AmazonAthena; Status Code: 400; Error 
Code: InvalidRequestException; Request ID: 
f8cd2762-1e7-a2f9-e5eb1d865406) 

答えて

2

をアマゾンアテナは、Amazon S3バケット内の各クエリの出力を保存します。エラーメッセージは、Athenaがこのバケットにアクセスできないことを示しています。

Settings link

  • Amazon S3の管理に確認し
  • (必要に応じてそれを変更して自由に感じる)バケット名が表示されていることを確認し、画面の上部
  • Settingsリンクをクリックしてくださいその名前のバケットが同じ領域に存在することをコンソールで確認します。そうでない場合は、バケットを作成します。

Bucket name