This topic describes how to manage file gateways in the Cloud Storage Gateway (CSG) console. For example, you can create, delete, and rename a gateway.
Prerequisites
An Alibaba Cloud account is created and real-name verification for the account is complete. For more information, see Create an Alibaba Cloud account.
NoteWe recommend that you log on to the CSG console as a RAM user. For more information, see Use RAM to implement account-based access control.
CSG is activated. If CSG is not activated, follow the on-screen instructions in the CSG console to activate CSG.
A virtual private cloud (VPC) is available in the region where you want to create the file gateway. For more information, see Create a VPC with an IPv4 CIDR block.
An Elastic Compute Service (ECS) instance is created on the VPC in the region where you want to create the file gateway. For more information about how to create an ECS instance, see Create an ECS instance.
NoteIf your on-premises host is connected to the VPC over an Express Connect circuit, you can also perform the steps by using the host.
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 file gateway
On the Gateways page of the CSG console, click Create.
In the Create Gateway wizard, configure parameters as described in the following table and retain default settings for other parameters.
In the Confirmation step, check the configuration information. If nothing is wrong, click Complete.
After the gateway is created, the system automatically deploys and starts the gateway. It takes about 5 to 10 minutes to complete the process. The gateway enters the Running state if it is activated and deployed.
After the gateway is created, the share specified in the gateway creation process is created. If the share does not meet your requirements, you can create a new share. For more information, see Attach a cache disk and Create a share.
Related operations
After you create a gateway, you can perform the following operations on the Gateways page.
Operation | Description |
Delete a gateway | Find the file gateway that you want to delete and click Delete. Note You can delete only pay-as-you-go gateways. |
Rename a gateway | Find the file gateway that you want to rename and choose More > Edit in the Actions column. |
Switch to subscription | You can switch the billing method of a gateway from pay-as-you-go to subscription. To switch to the subscription billing method, find the gateway and choose Switch the billing method from pay-as-you-go to subscription. . On the subscription page, purchase a subscription based on your requirements. For more information, seeImportant On the subscription page, do not modify any configuration settings other than the subscription duration. |
Upload supported data | To upload logs for troubleshooting, find the gateway and choose . |
Purchase a subscription | If you create a subscription gateway but have not completed the subscription payment, find the gateway and choose . |
Change the expiration policy | For a subscription gateway, you can choose Switch the expiration policy. to change the action when the current subscription expires. For more information, see |