mc mb

Creates buckets on local cluster/fabric or on remote fabrics present on the global namespace.

Syntax

CLI
mc mb [FLAGS] TARGET 

FLAGS:
  --account value               specify account that bucket should be created in
  --ignore-existing, -p         ignore if bucket/directory already exists
  --with-lock, -l               enable object lock
  --disable-versioning, -d      disable object versioning
  --json                        enable JSON lines formatted output
  --debug                       enable debug output
  --insecure                    disable SSL certificate verification
  --help, -h                    show help

Parameters

Parameter Description
TARGET The target string that includes the alias of a configured HPE Ezmeral Object Store deployment on which the command creates buckets. This is a mandatory parameter. To create buckets from a remote cluster/fabric in the global namespace use the format <fabricname>-<bucketname> instead of only the <bucketname> after the alias, that is <alias>/<fabricname>-<bucketname>.When bucketname is mentioned without the fabric name, Data Fabric creates a bucket with the specified name on the local cluster.
account The account on which the bucket is to be created. If not specified, buckets are created in the default account.
ignore-existing Ignores creation if the bucket already exists.
with-lock Enables Object Locking for the bucket.
disable-versioning Disables bucket versions. By default, bucket versions are enabled.
json Enable JSON formatted output.
debug Enable output for debugging.
insecure Disable SSL verification.
help Show this help.
ATTENTION
When you name a bucket, do not include mapr. as a prefix for the bucket name. For example, mapr.bucket1 is not supported.

Examples

NOTE
For the following examples, the object store deployment is identified by the alias salesalias.
  1. Create a bucket named northamerica in the Object Store deployment with alias salesalias:
    CLI
    /opt/mapr/bin/mc mb salesalias/northamerica
  2. Create a folder called brickfire inside the bucket named northamerica in the Object Store deployment that is identified by the alias salesalias:
    CLI
    /opt/mapr/bin/mc mb salesalias/northamerica/brickfire
  3. Create a bucket named northamerica on the remote fabric sales on the default account in the Object Store deployment with alias salesalias:
    CLI
    /opt/mapr/bin/mc mb --account=default salesalias/northamerica --cluster sales
  4. Create a bucket named northamerica with its versions disabled, on the remote fabric saleson the default account in the Object Store deployment with alias salesalias:
    CLI
    /opt/mapr/bin/mc mb --disable-versioning --account=default salesalias/sales-northamerica