AWS Glacier, cannot delete archive

0

I am successfully storing/retrieving archives, but I'm unable to delete any. I do the storing and retrieving through the .NET SDK in a desktop app, but I'm using PHP for deleting, so that's the only difference, but I seem to be doing everything else the same. I'm doing this:

$client = GlacierClient::factory(array(
			'region'  => 'us-east-1',
			'version' => 'latest',
			'key'    => '<KEY>',
    		'secret' => '<secret>'
		));

and am getting error: InvalidParameterValueException (client): Invalid vault name: arn:aws:glacier:us-east-1:1234567890:vaults/MyFiles

That is the exact region and name of the vault. Anyone have any idea what could be wrong?

asked a year ago269 views
1 Answer
1

You can delete one archive at a time from a vault. To delete the archive you must provide its archive ID in your delete request. You can get the archive ID by downloading the vault inventory for the vault that contains the archive.

https://docs.aws.amazon.com/amazonglacier/latest/dev/deleting-an-archive.html

AWS_Guy
answered a year ago
  • I know that. I am calling it correctly but it's giving me that error.

    $aws_result = $client->deleteArchive(array( 'accountId' => '123456789', 'vaultName' => 'MyFiles', 'archiveId' => 'shjgfasjdhfgjaksldghfjkasdgfjksdagfaksjd' ));

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions