This command creates a view, which is a resource location exposed to data clients. A view can be exposed to NFSv3, NFSv4.1 or SMB clients or to both NFSv3 and SMB clients or to both NFSv3 and NFSv4 clients.
Usage
view create --path PATH [--protocols PROTOCOLS] [--alias ALIAS] [--share SHARE] [--policy-id ID] [--create-dir] [--s3-versioning] [--s3-locks] [--s3-locks-retention-period S3_LOCKS_RETENTION_PERIOD] [--bucket BUCKET] [--bucket-owner BUCKET_OWNER] [--bucket-creators BUCKET_CREATORS] [--bucket-creators-groups BUCKET_CREATORS_GROUPS] [--allow-anonymous-access] [--block-anonymous-access]
Required Parameters
|
Specifies a path to a file system directory to be exposed to clients. It can be a directory that was already created by a client inside an exposed parent directory, or it can be a new directory, in which case you must specify the --create_dir option to create the directory. Example: --path /a/b/c |
Options
|
Specifies which protocol(s) the view will be exposed to. Specify PROTOCOLS as a string value for a single protocol or a comma separated list of strings to enable multiple protocols. Valid string values are:
Examples:
|
|
For NFSv3 exports, specifies an alternative shorter name for the path that can be used alternatively when mounting. Optional and relevant only if the view is exposed to NFS. An alias must begin with a forward slash ("/") and must consist of only ASCII characters. |
|
Specifies the SMB share name. Required if the view is exposed to SMB. The name cannot include the following characters: /\:|<>*?" |
|
Specifies which view policy to apply. If unspecified, the default policy (ID 1) is used. |
|
Creates a directory at the specified path. Include this option of the directory does not already exist. |
|
Enables object versioning on the bucket if |
|
Enables S3 object locking on the view bucket, if |
|
Sets a default retention period for objects in the bucket, if S3 object locking is enabled. If set, object versions that are placed in the bucket are automatically protected with the specified retention lock. Otherwise, by default, each object version has no automatic protection but can be configured with a retention period or legal hold. For more information, see S3 Object Locking Overview. Specify S3_LOCKS_RETENTION_PERIOD as an integer followed by a symbol. For example: 1y for one year. |
|
Specifies the name of an S3 bucket. Required if |
|
Specifies a user to be the bucket owner. Required if |
|
Relevant if Specify |
|
Relevant if Specify CautionTake extra care not to duplicate bucket creators through groups: If you specify a group as a bucket creator group in one view and you also specify a user who belongs to that group as a bucket creator user in another view, view creation will not fail. Yet, there is a conflict between the two configurations and the selection of a view for configuring the user's buckets is not predictable. |
|
If the view has S3 Bucket or S3 Endpoint enabled, include this option to allow anonymous S3 access to the view's S3 bucket. If allowed, anonymous requests are granted provided that the object ACL grants access to the All Users group (in S3 Native security flavor) or the permission mode bits on the requested file and directory path grant access permission to "others" (in NFS security flavor). |
|
Blocks anonymous S3 access to the view's S3 bucket, if applicable. This is the default setting. |
Example
This example creates a view of the pre-existing /dev
directory, with an NFS export, using the default view policy.
vcli: admin> view create --path /dev --protocols NFS
This example creates a multiprotocol view of a directory at the /home/users/devteam
path using a non default view policy.
vcli: admin> view create --path /home/users/devteam --protocols NFS,SMB --alias /devteam --share devteamusers --policy-id 2 --create-dir
Comments
0 comments
Article is closed for comments.