Notes
open one at a time
1.What it can cause
The broker writes no logs and no metrics, so when it misbehaves there is nothing to look at.
- The broker writes no logs and no metrics, so when it misbehaves there is nothing to look at.
- It cannot read secrets or fetch from Cloud Storage, so any change that needs them fails on this one VM.
- The tempting quick fix - giving it an external IP - undoes the design it was meant to follow.
2.Why it is wrong
Private Google Access is the flag that makes “no external IP” survivable. Turn it on before removing any address, never after.
The VM has no external IP, which is correct, but nothing gave it a private path to Google APIs. This is the flag you turn on before removing any external IP, not after.
The idea
Private Google Access is the flag that makes “no external IP” survivable. Turn it on before removing any address, never after.
Learn it
- Private Google Access · GCP 9
3.How you would find it
gcloud compute networks subnets list --filter="privateIpGoogleAccess=false" --format="table(name,region,ipCidrRange,privateIpGoogleAccess)"
gcloud compute networks subnets list \ --filter="privateIpGoogleAccess=false" \ --format="table(name,region,ipCidrRange,privateIpGoogleAccess)"4.The change that closes it
privateIpGoogleAccess: true - Google API hostnames resolve to 199.36.153.8/30 from inside the subnet
- As found
- privateIpGoogleAccess: false on sn-a-data
- Fixed
- privateIpGoogleAccess: true - Google API hostnames resolve to 199.36.153.8/30 from inside the subnet
gcloud compute networks subnets update sn-a-data \ --region=asia-southeast1 --enable-private-ip-google-access gcloud compute networks subnets describe sn-a-data \ --region=asia-southeast1 --format="value(privateIpGoogleAccess)"