1

I've deleted a table from the Glue Data Catalog but I want to restore it. I already track the event in CloudTrail but I don't know how to restore it.

  • If you are dumping your `cloudtrail` logs to the `S3`, then you can create Athena table for cloudtrail events and query for the Create Table event. – Mrugesh Kadia Aug 25 '22 at 11:40

1 Answers1

2

AWS Glue does not have any direct back-up methods, you can create your own solution that you periodically back-up your tables with for example the following command.

aws glue get-tables --database-name my-database > glue-my-database.json

and store this on a S3 with lifecycle management or even cross-region replication.

Restoring to AWS Glue can be done with the following AWS CLI command

aws glue create-table --cli-input-json ...

For your situation it seems that you are out of luck, the tables that are deleted will stay deleted.

Tom
  • 403
  • 3
  • 14