Aws glue database

0

Facing this error : @ Exception in User Class: org.apache.spark.sql.catalyst.analysis.AccessControlException: Unable to verify existence of default database: com.amazonaws.services.glue.model.GlueEncryptionException: User: arn:aws:sts:assumed-role/iamrole/GlueJobRunnerSession is not authorized to perform: kms:Decrypt on the resource associated with this ciphertext because no identity-based policy allows the kms:Decrypt action (Service: AWSKMS; Status Code: 400; Error Code: AccessDeniedException; Request ID: 504f921-bedb-4b63-a559-87d07d4ebaf5; Proxy: null) (Service: AWSGlue; Status Code: 400; Error Code: GluencryptionException; Request ID: d749798d-65f9-4180-b5d6-c91bd112747a; Proxy: null)

Madhu
已提問 9 個月前檢視次數 1012 次
1 個回答
0

You'd need to grant glue job service role kms:Decrypt access. From the error logs it's evident that it doesn't have access to KMS key here.

You need to find the KMS key and then add this permission to one of the policy in glue job service role. Once you add kms:Decrypt permission for that KMS key, this error would go away.

Refer Setting up encryption in AWS Glue and Encrypting data written by AWS Glue for more details and see which one applies to your case and accordingly add the permissions for kms:Decrypt.

Also make sure there are no explicit deny in that KMS key resource policy, you can check that by going to KMS console, select that key and check key policy.

Hope this helps.

Abhishek

profile pictureAWS
專家
已回答 9 個月前
  • Do you have any additional questions, happy to help.

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南