AWS CLI

You can install and use the AWS Command Line Interface (CLI) with the Object Store.

Installing the AWS CLI

To install the AWS CLI on Ubuntu, RedHat/CentOS, or SUSE, run:

pip install awscli
To configure the AWS CLI, use the AWS configure command with the values shown in the following table:
Value Description
AWS Access Key ID Insert the accessKey for the user
AWS Secret Access Key Insert the secretKey for the user
Default region name Specify 'us-west-1'
Default output format Specify json

Using the AWS CLI

The following table provides examples of commands that can help you manage buckets and files:
# Create a bucket and upload a file
aws s3 mb s3://mybucket/ --endpoint-url https://<ip-address>:9000 --ca-bundle /absolute/path/to/public.crt
        
echo "HelloS3World" > /tmp/helloS3world.txt
aws s3 cp /tmp/helloS3world.txt s3://mybucket/helloS3world.txt --endpoint-url https://<ip-address>:9000 --ca-bundle /absolute/path/to/public.crt
        
# Move an object from one bucket to another
aws s3 mv s3://firstbucket/helloS3world.txt s3://mybucket/helloS3world.txt --endpoint-url https://<ip-address>:9000 --ca-bundle /absolute/path/to/public.crt
        
# Delete an object from a bucket
aws s3 rm s3://mybucket/helloS3world.txt --endpoint-url https://<ip-address>:9000 --ca-bundle /absolute/path/to/public.crt
        
# Delete the bucket
aws s3 rb s3://mybucket/ --endpoint-url https://<ip-address>:9000 --ca-bundle /absolute/path/to/public.crt
        
# List all files in the bucket

aws s3 ls s3://mybucket/ --endpoint-url https://<ip-address>:9000 --ca-bundle /absolute/path/to/public.crt
        
# Show all files on the filesystem
ls -al /mapr/demo.mapr.com/apps/s3/$(hostname)/mybucket/

AWS CLI Limitations

If you list a folder in FS deployment mode and at least one of the files or buckets has permissions that deny access, an access-deny error is returned.