
Use the -force option as illustrated below to remove a bucket and all of its items: $ aws s3 rb s3://tgsbucket -force The provided bucket is deleted by the next command: Make_bucket failed: s3://demo-bucket An error occurred (IllegalLocationConstraintException) when calling the CreateBucket operation: The unspecified location constraint is incompatible for the region-specific endpoint this request was sent to. The preceding error may indeed appear in certain circumstances:


Please select a different name and try again. The bucket namespace is shared by all users of the system. You’ll see the next error notice if the bucket previously exists but is held by another user: $ aws s3 mb s3://paloalto make_bucket failed: s3://paloalto An error occurred (BucketAlreadyExists) when calling the CreateBucket operation: The requested bucket name is not available. Make_bucket failed: s3://tgsbucket An error occurred (BucketAlreadyOwnedByYou) when calling the CreateBucket operation: Your previous request to create the named bucket succeeded and you already own it.

The following error notice will appear if the bucket previously existed or you hold it: $ aws s3 mb s3://tgsbucket The bucket in the aforementioned example is created in the us-west-2 region.Īs indicated in the user’s configuration file, which is seen below: $ cat ~/.aws/config Make Bucket is abbreviated as mb.Ī new S3 bucket will be created by the following: $ aws s3 mb s3://tgsbucket Here we’re discussing some of the AWS S3 CLI Commands.
