- Newest
- Most votes
- Most comments
It looks like you're experiencing permission issues when trying to query the SageMaker Catalog exported metadata. The error "Insufficient permissions to execute the query" indicates that your role doesn't have the necessary Lake Formation permissions to access the asset table.
To resolve this issue, you need to:
-
Make sure you've enabled analytic services integration for S3 Tables.
-
Grant the appropriate Lake Formation permissions to your role. The correct format for granting permissions to the SageMaker Catalog asset table is:
aws lakeformation grant-permissions \
--principal DataLakePrincipalIdentifier=arn:aws:iam::<YOUR-ACCOUNT-ID>:role/<YOUR-ROLE> \
--resource '{"Table": {"CatalogId": "<YOUR-ACCOUNT-ID>:s3tablescatalog/aws-sagemaker-catalog", "DatabaseName": "asset_metadata", "Name": "asset"}}' \
--permissions DESCRIBE SELECT \
--region ap-southeast-1
Note that the CatalogId should include your account ID followed by :s3tablescatalog/aws-sagemaker-catalog. This is important because the catalog is a nested catalog within s3tablescatalog.
The error you're seeing when trying to grant permissions directly on s3tablescatalog is because you need to specify the full path to the nested catalog (aws-sagemaker-catalog) as shown in the command above.
Also, ensure that your IAM role has the necessary permissions for Lake Formation operations. You may need to add lakeformation:GrantPermissions and other Lake Formation permissions to your policy.
Sources
Exporting asset metadata - Amazon SageMaker Unified Studio
Querying metadata tables with AWS analytics services - Amazon Simple Storage Service
Troubleshooting S3 Metadata - Amazon Simple Storage Service
answered 10 months ago
Hello,
For "Make sure you've enabled analytic services integration for S3 Tables.", it's completed. But after ran command "aws lakeformation grant-permissions", received error message "An error occurred (InvalidInputException) when calling the GrantPermissions operation: Table not found."
Any ideas on this?
Thank you
answered 10 months ago
Relevant content
asked 10 months ago
