This topic describes how to create a share in the Cloud Storage Gateway (CSG) console. After a share is created, you can mount the share on a local directory. This share is linked to the Object Storage Service (OSS) bucket associated with the gateway, and any operations performed on the data within the share are applied directly to the corresponding data in the associated bucket.
Prerequisites
A file gateway is created, and a cache disk is attached to it. For more information, see Manage file gateways and Attach a cache disk.
An OSS bucket is created. For more information, see Get started by using the OSS console.
ImportantFile gateways support the following storage classes of OSS buckets: Standard, Infrequent Access (IA), and Archive. File gateways do not support OSS buckets for which back-to-origin routing is configured.
We recommend that you do not associate a gateway with an Archive bucket. If files that are written from a file gateway to OSS are infrequently modified, we recommend that you store the files in a Standard or IA bucket first and configure a lifecycle rule that changes the storage class of the files to Archive or Cold Archive. This reduces unnecessary restoration operations and optimizes storage costs and efficiency.
When a client writes a file to a file gateway, the gateway records at least two actions: writing the file and setting the file modification time. The gateway merges the two actions where possible. However, the gateway may still initiate multiple operations on the object to the bucket where the object is stored. The CopyObject operation is called to store the file modification time as a piece of metadata of the object in the bucket. If the object is an Archive or Cold Archive object, this operation requires object restoration, which takes some time to complete. This increases the time required for object uploads and even causes upload failures if not enough time is left to upload data in the cache.
Create a share
On the Gateways page, click the ID of the file gateway. On the page that appears, click .
In the Bucket Settings step, configure the parameters described in the following table.
In the Basic Information step, configure the parameters described in the following table.
(Optional) In the Advanced Settings step, configure the parameters described in the following table.
(Optional) In the Replication Mode Advanced Settings step, configure the parameters described in the following table.
In the Confirmation step, check the configuration information. If nothing is wrong, click Completed.