Creating a Filestore Instance

There are three ways to create a filestore instance namely:

  1. Cloud Console
  2. API
  3. GCloud commands

Let’s discuss these in detail.

Cloud Console

To create an instance with the cloud console follow the below steps:

Step 1: Navigate to the Filestore page in Cloud Console.

Step 2: Click on the Create Instance button and set up the configurations as follows:

  • Set Instance ID to nfs-server.
  • Set Instance type.
  • Set Storage type.
  • Set Allocate capacity
  • Set Region and Zone.
  • Set VPC network to default.
  • Set File share name.
  • Set Access controls to Grant access to all clients.

Step 3: Click on Create.

GCloud Command Line

To create an instance with Gcloud command line follow the below steps:

Step 1: Select or create a GCP project using the below commands:

gcloud projects create project-id
 
or,
 
gcloud config set project-id

Step 2: Verify if billing is enabled for your Google Cloud Platform project.

Step 3: Install and initialize the Cloud SDK using the below command:

gcloud components update

Step 4: Now create the compute engine VM as a client as shown below:

For Linux:

gcloud compute instances create nfs-client
  --zone us-central1-c
   --image-project debian-cloud
    --image-family debian-10
     --tags http-server,

For Windows:

gcloud compute instances create nfs-client
 --zone us-central1-c
  --image-project windows-cloud
   --image-family windows-2012-r2
    --tags http-server,http-server,

Note: The region, zone, and capacity may vary depending upon your setup.

Step 5: Now use the following commands to create an instance of Filestore as shown below:

gcloud beta filestore instances create nfs-server
 --zone=us-central1-c
  --tier=BASIC_HDD
   --file-share=name="Myfile",capacity=1TB
    --network=name="default"

Step 6: Now verify the configuration using the below command:

gcloud filestore instances describe nfs-server --zone=us-central1-c

This would result in something like below:

createTime: '2019-10-11T17:28:23.340943077Z'
fileShares:
- capacityGb: '1024'
 name: vol1
name: projects/yourproject/locations/us-central1-c/instances/nfs-server
networks:
- ipAddresses:
 - 10.0.0.2
 network: default
 reservedIpRange: 10.0.0.0/29
state: READY
tier: BASIC_HDD

Google Cloud Platform – Filestore

GCP’s Filestore is a managed file storage service for applications that require a file system interface and a shared file system for data. It gives the user a native experience for standing up managed network detached storage with their VM in the compute engine and Google Kubernetes Engine. It offers low latency for file operations, therefore making it perfect for workloads like data analytics, media rendering, genomic processing, or other media-intensive applications. It provides performance tier and storage capacity which enables users to tune the file system for a particular workload.

Similar Reads

Creating a Filestore Instance

There are three ways to create a filestore instance namely:...

Use Cases

Filestore has the following principal use cases:...