Amazon Glacier Cheat Sheet

LIST JOBS

aws glacier list-jobs --account-id [AccountId] --vault-name [VaultName] 

INVENTORY RETRIEVAL

aws glacier initiate-job --account-id [AccountId] --vault-name [VaultName] --job-parameters file://[InputFilename]

Where [InputFilename] contains the following (GitHub Gist)

{
    "Type": "inventory-retrieval"
}

ARCHIVE RETRIEVAL

aws glacier initiate-job --vault-name [VaultName] --account-id [AccountId]  --job-parameters file://[InputFilename]

Where [InputFilename] contains the following (GitHub Gist)

{
  "Type": "archive-retrieval",
  "ArchiveId": "[ArchiveId]"
}

GET JOB

aws glacier get-job-output --account-id [AccountId] --vault-name [VaultName] --job-id [JobId] [OutputFilename]

Leave a Reply

Your email address will not be published. Required fields are marked *