Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Snapshots of my VM instance are not being created

I have snapshot instances main-instance-backup and free-instance-backup:

free-instance-backup us-central1 Every day, starts between 6:00 AM and 7:00 AM 7 days
not in use
Dec 10, 2022, 12:19:59 AM UTC+02:00
main-instance-backup us-central1 Every day, starts between 6:00 AM and 7:00 AM 14 days
not in use
Apr 30, 2023, 11:46:06 PM UTC+03:00

vporton_0-1682987279978.png

But new snapshots are not being created:

vporton_1-1682987306048.png

Here is my VM instance-2 that is not being backuped every day:

vporton_2-1682987356655.png

Please help me to make backups work!!

0 1 1,636
1 REPLY 1

Hello vporton,

As per dasalemi,

"According to GCP public documentation, to list the available  snapshots, you need to have the permission compute.snapshots.list assigned on the project.

After reviewing and assigning the permission required, please try to list the snapshots available by running:

gcloud compute snapshots list --project PROJECT_ID

where PROJECT_ID is the ID of the project."

You can check your "Logs Explorer" as well to see if there were any error messages when you tried to create your snapshots.

If the error were You can only use guest-flush on disks attached to instances with supported operating systems.  Make sure you have the latest image version and agent installed with required services (e.g. VSS for Windows).

Enabling guest-flush (`Enabled Volume Copy Shadow Service (VSS)`), as this is instance is an Ubuntu based image, to allow the snapshot to be taken successfully you have to follow the instruction for Linux application consistent disk snapshots as described here, basically creating custom pre and post snapshot scripts, then edit your guest environment configuration file lastly create a snapshot schedule with guest-flush enabled by modifying and running the following command in the cloud shell

gcloud compute resource-policies create snapshot-schedule SCHEDULE_NAME \
  --description "MY SNAPSHOT SCHEDULE" \
  --start-time 22:00 \
  --hourly-schedule 4 \
  --guest-flush

and then apply the schedule snapshot.

If you still have problems viewing the available snapshots, please contact the support team, since this problem will require review of your particular project.