Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Halaman ini menjelaskan cara melakukan tugas umum untuk fitur snapshot RDB.
Untuk mengetahui detail tentang fitur snapshot RDB, lihat ringkasan snapshot RDB.
Membuat instance yang menggunakan snapshot RDB
Konsol
Buka halaman Memorystore for Redis di Google Cloud konsol.
Pilih interval snapshot dari dropdown Snapshot Interval.
Kembali ke petunjuk Membuat instance Redis di jaringan VPC untuk mendapatkan panduan tambahan tentang konfigurasi Memorystore lainnya, lalu klik tombol Create.
gcloud
Untuk mengaktifkan snapshot RDB pada instance, masukkan perintah berikut
yang mengganti variables dengan nilai yang sesuai:
snapshot-interval adalah interval yang Anda inginkan. Nilai yang dapat diterima
adalah: 1h, 6h, 12h, dan 24h.
Menjeda snapshot
gcloud
Untuk menjeda snapshot, Anda harus menetapkan jadwal snapshot ke waktu mendatang.
Jika ingin melanjutkan jeda snapshot, Anda dapat menyesuaikan kembali waktu saat Anda
ingin snapshot berikutnya terjadi. Misalnya, untuk menjeda snapshot, masukkan perintah berikut yang mengganti variables dengan nilai yang sesuai:
[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Sulit dipahami","hardToUnderstand","thumb-down"],["Informasi atau kode contoh salah","incorrectInformationOrSampleCode","thumb-down"],["Informasi/contoh yang saya butuhkan tidak ada","missingTheInformationSamplesINeed","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-08-19 UTC."],[],[],null,["# Manage RDB snapshots\n\nThe page explains how to perform common tasks for the RDB snapshots feature.\nFor details on RDB snapshots feature, refer to [RDB snapshots overview](/memorystore/docs/redis/rdb-snapshots).\n| **Note:** During the Preview stage of the RDB Snapshots feature you cannot enable RDB Snapshots for existing Redis instances. You can only enable snapshots when creating a new Redis instance.\n\nCreating an instance that uses RDB snapshots\n--------------------------------------------\n\n### Console\n\n1. Go to the **Memorystore for Redis** page in the Google Cloud console.\n\n [Memorystore for Redis](https://console.cloud.google.com/memorystore/redis/instances?)\n2. Follow the instructions at [Creating a Redis instance on a VPC network](/memorystore/docs/redis/create-manage-instances#creating_a_redis_instance_on_a_vpc_network),\n but return to these instructions when you reach the **Snapshots** section.\n\n3. Select **Select Redis Database (RDB) snapshot**.\n\n 1. Choose a start time from the **Start Time** dropdown.\n 2. Choose a snapshot interval from the **Snapshot Interval** dropdown.\n4. Return to the [Creating a Redis instance on a VPC network](/memorystore/docs/redis/create-manage-instances#creating_a_redis_instance_on_a_vpc_network)\n instructions for\n additional guidance on other Memorystore configurations,\n and click the **Create** button.\n\n### gcloud\n\nTo enable RDB snapshots on an instance, enter the following command\nreplacing \u003cvar translate=\"no\"\u003evariables\u003c/var\u003e with appropriate values: \n\n```\ngcloud redis instances create instance-id --size=size --persistence-mode=rdb --rdb-snapshot-period=snapshot-interval --rdb-snapshot-start-time=time --region=region-id\n```\n\nWhere:\n\n- \u003cvar translate=\"no\"\u003esnapshot-interval\u003c/var\u003e is your desired interval. Accepted values are: `1h`, `6h`, `12h`, and `24h`.\n- \u003cvar translate=\"no\"\u003etime\u003c/var\u003e is your desired start time in the ISO 1801 format. For example: `2021-01-02T03:00:00Z`.\n\nEnabling snapshots on an existing instance\n------------------------------------------\n\n### Console\n\n1. Go to the **Memorystore for Redis** page in the Google Cloud console.\n\n [Memorystore for Redis](https://console.cloud.google.com/memorystore/redis/instances?)\n2. Click the ID of the instance you want to add RDB snapshots to.\n\n3. Find the *Snapshots* section.\n\n4. Select **Schedule Redis Database (RDB) snapshot**.\n\n 1. Choose a start time.\n\n 2. Choose a snapshot interval.\n\n5. Click the **Save** button.\n\n### gcloud\n\nRun the following command, replacing \u003cvar translate=\"no\"\u003evariables\u003c/var\u003e with appropriate\nvalues: \n\n```\ngcloud redis instances update instance_id --region=region --persistence-mode=rdb --rdb-snapshot-period=snapshot-interval --rdb-snapshot-start-time=time\n```\n\nWhere:\n\n- \u003cvar translate=\"no\"\u003esnapshot-interval\u003c/var\u003e is your desired interval. Accepted values are `1h`, `6h`, `12h`, and `24h`.\n- \u003cvar translate=\"no\"\u003etime\u003c/var\u003e is your desired start time in the ISO 1801 format. For example: `2021-01-02T03:00:00Z`.\n\nAdjusting snapshot schedule\n---------------------------\n\n### gcloud\n\nTo adjust the schedule of RDB snapshots, enter the following command\nreplacing \u003cvar translate=\"no\"\u003evariables\u003c/var\u003e with appropriate values: \n\n```\ngcloud redis instances update instance-id --rdb-snapshot-start-time=time --region=region\n```\n\nWhere:\n\n- \u003cvar translate=\"no\"\u003etime\u003c/var\u003e is your desired start time in the ISO 1801 format. For example: `2021-01-02T03:00:00Z`.\n\nAdjusting snapshot interval\n---------------------------\n\n### Console\n\n1. Go to the **Memorystore for Redis** page in the Google Cloud console.\n\n [Memorystore for Redis](https://console.cloud.google.com/memorystore/redis/instances?)\n2. Click the **Instance ID** of the instance you'd like to edit.\n\n3. Click the **Edit** button\n\n4. Find the **Snapshots** section.\n\n5. Use the **Snapshot Interval** dropdown to select your desired interval.\n\n6. Click the **Save** button.\n\n### gcloud\n\nTo change the snapshot interval, enter the following command\nreplacing \u003cvar translate=\"no\"\u003evariables\u003c/var\u003e with appropriate values: \n\n```\ngcloud redis instances update instance-id --rdb-snapshot-period=snapshot-interval\n--region=region\n```\n\nWhere:\n\n- \u003cvar translate=\"no\"\u003esnapshot-interval\u003c/var\u003e is your desired interval. Acceptable values are: `1h`, `6h`, `12h`, and `24h`.\n\nPausing snapshots\n-----------------\n\n### gcloud\n\nTo pause snapshots, you must to set the snapshot schedule to a future time.\nWhen you want to unpause snapshots, you can re-adjust the time to when you\nwant the next snapshot to occur. For example, to pause snapshots, enter the\nfollowing command replacing \u003cvar translate=\"no\"\u003evariables\u003c/var\u003e with appropriate values: \n\n```\ngcloud redis instances update instance-id --rdb-snapshot-start-time=2022-06-10T03:00:00Z\n--region=region\n```\n| **Note:** Pausing snapshots will result in stale backups and can result in the instance being recovered with stale data. If you need to pause snapshots for a long period of time, consider disabling RDB snapshot instead.\n\nDisabling RDB snapshots\n-----------------------\n\n### Console\n\n1. Go to the **Memorystore for Redis** page in the Google Cloud console.\n\n [Memorystore for Redis](https://console.cloud.google.com/memorystore/redis/instances?)\n2. Click the **Instance ID** of the instance you'd like to edit.\n\n3. Click the **Edit** button\n\n4. Unselect **Schedule Redis Database (RDB) snapshot**.\n\n | **Note:** This action stops ongoing snapshots and deletes existing snapshots.\n5. Click the **Save** button.\n\n### gcloud\n\nTo disable RDB snapshots for a Redis instance, enter the following command\nreplacing \u003cvar translate=\"no\"\u003evariables\u003c/var\u003e with appropriate values: \n\n```\ngcloud redis instances update instance-id --persistence-mode=disabled --region=region\n```\n| **Note:** Running this command stops ongoing snapshots and deletes existing snapshots.\n\nMonitoring RDB snapshots\n------------------------\n\n### Console\n\nThe **Instance details** page for Redis instance provides the following RDB\nsnapshots metrics:\n\n- Frequency\n- Next snapshot\n- Last snapshot status\n- Time since last snapshot\n- Time of last restore\n\nTo view these details:\n\n1. Go to the **Memorystore for Redis** page in the Google Cloud console.\n\n [Memorystore for Redis](https://console.cloud.google.com/memorystore/redis/instances?)\n2. Click the **Instance ID** of your instance.\n\n3. View the snapshot information under the **RDB Snapshots** section.\n\n### Cloud Monitoring\n\nYou can use [Cloud Monitoring](/memorystore/docs/redis/monitoring-instances)\nto view metrics for RDB snapshots.\n\nFor a list of available metrics for RDB snapshots, see [RDB snapshots metrics](/memorystore/docs/redis/monitoring-metrics#rdb_snapshots_metrics).\n\nWhat's next\n-----------\n\n- See the overview of [RDB Snapshots](/memorystore/docs/redis/rdb-snapshots) for Memorystore.\n- Learn more about [importing and exporting](/memorystore/docs/redis/import-export-overview) data."]]