实验设置说明和要求
保护您的账号和进度。请务必在无痕浏览器窗口中,使用实验凭证运行此实验。

Protect your Google Cloud NetApp Volumes data with snapshots

实验 40 分钟 universal_currency_alt 1 个点数 show_chart 入门级
info 此实验可能会提供 AI 工具来支持您学习。
此内容尚未针对移动设备进行优化。
为获得最佳体验,请在桌面设备上访问通过电子邮件发送的链接。

This lab was developed with our partner, NetApp. Your personal information may be shared with NetApp, the lab sponsor, if you have opted-in to receive product updates, announcements, and offers in your Account Profile.

GSP1312

Google Cloud Self-Paced Labs

Overview

Google Cloud NetApp Volumes is a fully managed data storage service that lets you move file-based applications to Google Cloud. It has support for Network File System (NFSv3 and NFSv4.1) and Server Message Block (SMB) protocols built-in, so you don't need to re-architect your applications and can continue to get persistent storage for your applications.

Snapshots are virtual point-in-time versions of a volume that are taken on a scheduled basis. You can access snapshots using standard file system commands. Snapshots provide a RPO of as little as one hour. RTO depends on the amount of data you have to restore and is primarily limited by the volume throughput limit. Snapshots also allow users to restore specific files and directories, which decreases RTO even further. Snapshots only consume additional volume space for changes made to the volume.

In this lab you will learn how to manage Google Cloud NetApp Volumes snapshots.

Objectives

In this lab you will learn how to:

  • Create manual snapshots.
  • Schedule snapshots.
  • Restore a specific data from a snapshot.
  • Revert a volume from a snapshot.

Prerequisites

Setup and requirements

Before you click the Start Lab button

Read these instructions. Labs are timed and you cannot pause them. The timer, which starts when you click Start Lab, shows how long Google Cloud resources will be made available to you.

This Qwiklabs hands-on lab lets you do the lab activities yourself in a real cloud environment, not in a simulation or demo environment. It does so by giving you new, temporary credentials that you use to sign in and access Google Cloud for the duration of the lab.

What you need

To complete this lab, you need:

  • Access to a standard internet browser (Chrome browser recommended).
  • Time to complete the lab.

Note: If you already have your own personal Google Cloud account or project, do not use it for this lab.

Note: If you are using a Pixelbook, open an Incognito window to run this lab.

How to start your lab and sign in to the Google Cloud Console

  1. Click the Start Lab button. If you need to pay for the lab, a pop-up opens for you to select your payment method. On the left is a panel populated with the temporary credentials that you must use for this lab.

    Open Google Console

  2. Copy the username, and then click Open Google Console. The lab spins up resources, and then opens another tab that shows the Sign in page.

    Sign in

    Tip: Open the tabs in separate windows, side-by-side.

  3. In the Sign in page, paste the username that you copied from the Connection Details panel. Then copy and paste the password.

    Important: You must use the credentials from the Connection Details panel. Do not use your Qwiklabs credentials. If you have your own Google Cloud account, do not use it for this lab (avoids incurring charges).

  4. Click through the subsequent pages:

    • Accept the terms and conditions.
    • Do not add recovery options or two-factor authentication (because this is a temporary account).
    • Do not sign up for free trials.

After a few moments, the Cloud Console opens in this tab.

Activate Cloud Shell

Cloud Shell is a virtual machine that is loaded with development tools. It offers a persistent 5GB home directory and runs on the Google Cloud. Cloud Shell provides command-line access to your Google Cloud resources.

In the Cloud Console, in the top right toolbar, click the Activate Cloud Shell button.

Cloud Shell icon

Click Continue.

cloudshell_continue.png

It takes a few moments to provision and connect to the environment. When you are connected, you are already authenticated, and the project is set to your PROJECT_ID. For example:

Cloud Shell Terminal

gcloud is the command-line tool for Google Cloud. It comes pre-installed on Cloud Shell and supports tab-completion.

You can list the active account name with this command:

gcloud auth list

(Output)

Credentialed accounts: - <myaccount>@<mydomain>.com (active)

(Example output)

Credentialed accounts: - google1623327_student@qwiklabs.net

You can list the project ID with this command:

gcloud config list project

(Output)

[core] project = <project_ID>

(Example output)

[core] project = qwiklabs-gcp-44776a13dea667a6

Task 1. Mount the volume

  1. In the Google Cloud console search bar (google cloud console search bar icon), type NetApp Volumes and select the result to open the service.

  2. In the navigation pane, click Volumes. A volume (volume1) has already been created for this lab.

  3. Open Compute Engine → VM Instances in a new browser tab and click the SSH button for vm1.

  4. Return to the NetApp Volumes page. In the row for the volume (volume1), click the overflow menu (overflow menu icon), then select Mount Instructions.

  5. Run the following commands from the Mount instructions into the SSH window in the following order:

  • Install the nfs utilities on the Linux VM:
sudo apt-get install nfs-common -y
  • Create a directory in the VM:
sudo mkdir /share1
  • Mount the volume by copying the sudo mount command from the Mount instructions and running it in the SSH terminal. The command includes the unique IP address of the volume. It will look like the command below:
sudo mount -t nfs -o rw,hard,rsize=65536,wsize=65536,vers=3,tcp <IP_ADDRESS>:/share1 /share1 Note: Please run the mount command exactly as it appears in your specific Mount instructions panel, as the IP address in this command is unique to your volume.
  • Verify that the volume has been mounted to your VM successfully:
df -h | grep share1

Click Check my progress to verify that you've performed the above task. Mount the volume

Task 2. Create a manual snapshot

  1. In vm1, create folders and files by running the following commands:
sudo mkdir /share1/folder1 sudo mkdir /share1/folder2 sudo bash -c 'echo "important" > /share1/file1.txt' sudo bash -c 'echo "top secret" > /share1/file2.txt'
  1. List the contents of the volume:
sudo ls /share1
  1. In the Google Cloud console, go to the NetApp Volumes page.

  2. In the navigation pane, click Volumes.

  3. In the row for the volume (volume1), click the overflow menu (overflow menu icon), then select Create snapshot.

  4. For the Snapshot name, type snapshot1

  5. Skip the remaining options and click Create.

  6. Click volume1, then click the Snapshots tab. Verify that your new snapshot appears in the list.

Click Check my progress to verify that you've performed the above task. Create a manual snapshot

Task 3. Restore a file from a snapshot

You can use snapshots to restore deleted or corrupted files and directories using file access operations based on your operating system. While this lab demonstrates the process using a Linux client, the same functionality is available for Windows clients.

  1. In the navigation pane, click Volumes.

  2. Click volume1, then click Edit.

  3. Expand the Snapshot configuration section and verify that Make snapshot directory visible is enabled.

  4. In vm1, delete a file by running the following command:

sudo rm /share1/file1.txt
  1. Verify that file1 has been deleted:
sudo ls /share1
  1. View the mount point to see the hidden .snapshot folder. This folder contains all snapshots for the volume:
sudo ls -la /share1
  1. List the contents of the .snapshot folder to see snapshot1, which was created in the previous task:
sudo ls -la /share1/.snapshot
  1. List the contents of snapshot1. You will see that file1, which was deleted from the active filesystem, is preserved here:
sudo ls -la /share1/.snapshot/snapshot1
  1. Restore file1 to the active filesystem by copying it from the snapshot:
sudo cp /share1/.snapshot/snapshot1/file1.txt /share1/
  1. Verify that file1 is restored and visible in the active filesystem:
sudo ls /share1

Task 4. Schedule the snapshots of a volume

NetApp Volumes allows you to create manual snapshots and also includes an integrated snapshot scheduler.

  1. In the navigation pane, click Volumes.

  2. Click volume1, then click Edit.

  3. Expand the Snapshot configuration section and select the Allow scheduled snapshots checkbox.

Note: Once enabled, snapshots are created automatically according to the schedule configured. You can specify the number of snapshots to keep at hourly, daily, weekly, and monthly snapshot intervals.
  1. You can customize the scheduled snapshots configuration based on your RPO needs. Include the following configuration:
  • Hourly: Snapshots to keep = 24 (Minute = 0)
  • Daily: Snapshots to keep = 7 (Hour = 0, Minute = 0)
  • Weekly: Snapshots to keep = 8 (Weekdays = Sunday, Hour = 0, Minute = 0)
  • Monthly: Snapshots to keep = 3 (Days of the month = 1, Hour = 0, Minute = 0)
  1. Click Save

Click Check my progress to verify that you've performed the above task. Schedule volume snapshots

Task 5. Restore the entire volume from a snapshot

Google Cloud NetApp Volumes lets you revert a volume to a previous state using the data captured in a snapshot. Volume reversion restores all the contents of a volume back to the point in time a snapshot was taken

  1. In vm1, delete all the files previously created by running the following command:
sudo rm /share1/file1.txt sudo rm /share1/file2.txt sudo rm -rf /share1/folder1 sudo rm -rf /share1/folder2
  1. Verify that the files have been deleted:
sudo ls /share1
  1. In the Google Cloud console, go to the NetApp Volumes page.

  2. In the navigation pane, click Volumes.

  3. Click volume1, then click the Snapshots tab. Verify that snapshot1 appears in the list.

  4. In the row for the snapshot (snapshot1), click the overflow menu (overflow menu icon), then select Revert.

  5. Review the details and click Revert.

  6. To confirm the action, type the volume name (volume1) and click Revert.

    Note: Reverting a volume is a permanent action that cannot be undone. If it feels like it is taking too long to complete, click **Refresh**.
  7. In vm1, verify that the files and folders have been recovered:

sudo ls /share1

Click Check my progress to verify that you've performed the above task. Revert the volume

Congratulations!

You have learned how to create manual snapshots, scheduled snapshots, restore specific data from a snapshot, and restore an entire volume from a snapshot.

Next steps / Learn more

Be sure to check out the official NetApp Volumes documentation:

Google Cloud training and certification

...helps you make the most of Google Cloud technologies. Our classes include technical skills and best practices to help you get up to speed quickly and continue your learning journey. We offer fundamental to advanced level training, with on-demand, live, and virtual options to suit your busy schedule. Certifications help you validate and prove your skill and expertise in Google Cloud technologies.

Manual last updated January 12, 2026

Manual Last tested January 12, 2026

Copyright 2024 Google LLC All rights reserved. Google and the Google logo are trademarks of Google LLC. All other company and product names may be trademarks of the respective companies with which they are associated.

准备工作

  1. 实验会创建一个 Google Cloud 项目和一些资源,供您使用限定的一段时间
  2. 实验有时间限制,并且没有暂停功能。如果您中途结束实验,则必须重新开始。
  3. 在屏幕左上角,点击开始实验即可开始

使用无痕浏览模式

  1. 复制系统为实验提供的用户名和密码
  2. 在无痕浏览模式下,点击打开控制台

登录控制台

  1. 使用您的实验凭证登录。使用其他凭证可能会导致错误或产生费用。
  2. 接受条款,并跳过恢复资源页面
  3. 除非您已完成此实验或想要重新开始,否则请勿点击结束实验,因为点击后系统会清除您的工作并移除该项目

此内容目前不可用

一旦可用,我们会通过邮件告知您

太好了!

一旦可用,我们会通过邮件联系您

一次一个实验

确认结束所有现有实验并开始此实验

使用无痕浏览模式运行实验

使用无痕模式或无痕浏览器窗口是运行此实验的最佳方式。这可以避免您的个人账号与学生账号之间发生冲突,这种冲突可能导致您的个人账号产生额外费用。