Newbie in AWS Glacier - how to connect to my storage and upload files there via PowerShell?

0

Hi,

I'm a newbie with S3 and would like to know step by step how to connect, upload and read file(s) to my S3 Glacier storage via PowerShell? Link https://docs.aws.amazon.com/powershell/latest/reference/items/New-GLCVault.html looks very uninformative and convoluted regarding credentials to be used for connecting, and also has no samples to play with. Could anybody describe me step by step how to connect from my PowerShell console and do all the described steps for S3? AWSPowerShell.NetCore was installed on my Win machine, so cmdlets seem to be available. Thanks in advance!

asked 10 months ago404 views
4 Answers
0

Ok, I tried to run New-S3Bucket cmd but got this error:

PS C:!> New-S3Bucket -BucketName website-example -Region us-west-2 New-S3Bucket : Access Denied At line:1 char:1

  • New-S3Bucket -BucketName website-example -Region us-west-2
  • CategoryInfo : InvalidOperation: (Amazon.PowerShe...wS3BucketCmdlet:NewS3BucketCmdlet) [New-S3Bucket], AmazonS3Exception
  • FullyQualifiedErrorId : Failed to create the specified bucket. Amazon S3 error: Access Denied,Amazon.PowerShell.Cmdlets.S3.NewS3BucketCmdlet

Write-S3Object led to the same error. What should I do to get these cmdlets working?

answered 9 months ago
  • "Access denied" is the standout for me here: You don't appear to have permissions to do that.

0

@Brettski-AWS, could you please tell me where and how can I give the proper rights for using Write-S3Object? I granted my user FullAccessRight before , but it doesn't seem to work.

answered 9 months ago
  • In IAM (in the AWS console) try assigning the AmazonS3FullAccess policy to your user. I'd caution that you should cut down the permissions the user has in a production environment. Note that if you're part of a larger AWS Organization your ability to perform certain tasks may be restricted by a Service Control Policy.

0
profile pictureAWS
EXPERT
answered 10 months ago
0

While you can use Glacier in the way described in the other answer (and there's nothing wrong with that - it was how Glacier was originally designed to operate), Glacier can also be used as a storage class in S3 which can be simpler and takes away the need to handle vaults and so on - you just upload the objects you like and use the appropriate "storage class" parameter to tell S3 to put the files into Glacier.

If you are a newbie then I'd recommend going down the S3 storage class path because it is simpler and easier to deal with. Vaults still have their advantages but if you don't need to then go the other way.

profile pictureAWS
EXPERT
answered 10 months ago

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