0

I am facing some hard time in AWS s3 batch operation job to restore objects from deep archive storage class to standard. I am using s3 batch operation job with restore operation. I have created manifest file using s3 inventory. When I create job using that manifest the job failed because bucket contain objects in deep archieve and standard class both, when job encounter with objects that are in standard class it failed. This is error message in job report.

Restore is not allowed for the object's current storage class (Service: Amazon S3; Status Code: 403; Error Code: InvalidObjectState; Request ID: CBKBCAHF9RJJY180; S3 Extended Request ID: ut4csBUfR+c1rSZQMVga1h+WNS6hiddXB2ANj7vvtAOlv8YtavgUM/droJ09qqi2ZMmqVQFOby8=; Proxy: null) 

When I check the object for this error message it was in standard storage class. There are more then 2 million objects in bucket so its impossible to create inventory by hard coding. Is there any way that batch job only process the items that are in deep archive storage class. Thank you

1 Answers1

0

You should use Amazon S3 Inventory, which can provide a daily or weekly CSV file listing all objects.

The CSV file includes the storage class, so you could edit the file to only include objects in the Deep Archive storage class.

Amazon S3 Batch Operations accepts the S3 Inventory file as input for batch operations.

John Rotenstein
  • 241,921
  • 22
  • 380
  • 470