📜  gcp storageclass types (1)

📅  最后修改于: 2023-12-03 14:41:22.368000             🧑  作者: Mango

GCP StorageClass Types

GCP provides different types of storage classes to fit different use cases and performance needs. Storage classes can be specified at the time of creating a bucket or object.

Standard Storage Class

The Standard storage class is meant for frequently accessed data, such as website content, interactive workloads, or data that’s accessed regularly. It offers low latency and high throughput performance.

To create a bucket with the Standard storage class, use the following command:

gsutil mb -c standard -l [BUCKET_LOCATION] gs://[BUCKET_NAME]
Nearline Storage Class

The Nearline storage class is meant for data that is accessed less frequently, typically once a month or less. It offers lower costs than the Standard storage class, but at the expense of slightly higher retrieval costs.

To create a bucket with the Nearline storage class, use the following command:

gsutil mb -c nearline -l [BUCKET_LOCATION] gs://[BUCKET_NAME]
Coldline Storage Class

The Coldline storage class is meant for data that is archived and accessed even less frequently, typically once a year or less. It offers the lowest storage costs, but at the expense of higher retrieval costs and longer retrieval times.

To create a bucket with the Coldline storage class, use the following command:

gsutil mb -c coldline -l [BUCKET_LOCATION] gs://[BUCKET_NAME]
Archive Storage Class

The Archive storage class is meant for long-term data archival, where data retention is of the utmost importance but data access is highly infrequent. It offers the lowest storage costs, but at the expense of higher retrieval costs and longer retrieval times.

To create a bucket with the Archive storage class, use the following command:

gsutil mb -c archive -l [BUCKET_LOCATION] gs://[BUCKET_NAME]
Multi-Regional Storage Class

The Multi-Regional storage class is meant for data that needs to be highly available and accessible from multiple regions. It offers high availability, low latency, and high throughput performance.

To create a bucket with the Multi-Regional storage class, use the following command:

gsutil mb -c multi_regional -l [BUCKET_LOCATION] gs://[BUCKET_NAME]
Regional Storage Class

The Regional storage class is meant for data that needs to be highly available and accessible from a single region. It offers high availability, low latency, and high throughput performance.

To create a bucket with the Regional storage class, use the following command:

gsutil mb -c regional -l [BUCKET_LOCATION] gs://[BUCKET_NAME]
Conclusion

In conclusion, GCP provides a variety of storage classes to choose from, depending on the performance and cost requirements of your particular application. It's important to choose the right storage class to optimize the costs and performance of your application.