I am trying to follow a tutorial that came up on the google cloud platform console for creating a MongoDB application using Compute Engine. I follow the tutorial for creating the VMs but they are not created and return the following error:
Invalid value for field 'resource.networkInterfaces.network': ''. The referenced network resource cannot be found.
Any idea what this could be? I have not created any VMs previously so am unsure what this is. I am not using commandline, I am using the console to do this.
I just experienced the same thing trying to create a VM on a fresh project. It looks like Google is having problems provisioning new projects (at least the compute engine networking stuff).
You'll have to manually create the default network. Here's how to do that:
Activate the Google Cloud Shell (button in upper right of Cloud Console website), then run these commands:
gcloud compute networks create default gcloud compute firewall-rules create default-allow-icmp --network default --allow icmp --source-ranges 0.0.0.0/0 gcloud compute firewall-rules create default-allow-ssh --network default --allow tcp:22 --source-ranges 0.0.0.0/0 gcloud compute firewall-rules create default-allow-internal --network default --allow tcp:0-65535,udp:0-65535,icmp --source-ranges 10.128.0.0/9
After that, you should be able to create VMs.
Another option would be to complain to Google.. This is not normal behavior.
worked for me. Network (subnet) already existed in my case (unlike the case of @Ray) hence just mentioning the name of the subnet (default in general) helped.