kubernetes/kops · error
error creating Instance: %v
Error message
error creating Instance: %v
What it means
Wrapped error from Instance.RenderGCE when the synchronous Instances.Insert call fails for a new instance (a == nil). GCE rejected the create — typical causes are quota, invalid machine type/zone, missing dependencies (network/subnet/IP conflicts), or permissions.
Source
Thrown at upup/pkg/fi/cloudup/gcetasks/instance.go:331
func (_ *Instance) RenderGCE(t *gce.GCEAPITarget, a, e, changes *Instance) error {
cloud := t.Cloud
project := cloud.Project()
zone := *e.Zone
ipAddressResolver := func(ip *Address) (*string, error) {
return ip.IPAddress, nil
}
i, err := e.mapToGCE(project, ipAddressResolver)
if err != nil {
return err
}
if a == nil {
klog.V(2).Infof("Creating instance %q", i.Name)
if _, err := cloud.Compute().Instances().Insert(project, zone, i); err != nil {
return fmt.Errorf("error creating Instance: %v", err)
}
} else {
if changes.Metadata != nil {
klog.V(2).Infof("Updating instance metadata on %q", i.Name)
i.Metadata.Fingerprint = a.metadataFingerprint
op, err := cloud.Compute().Instances().SetMetadata(project, zone, i.Name, i.Metadata)
if err != nil {
return fmt.Errorf("error setting metadata on instance: %v", err)
}
if err := cloud.WaitForOp(op); err != nil {
return fmt.Errorf("error setting metadata on instance: %v", err)
}
changes.Metadata = nil
}View on GitHub (pinned to 4c8573c808)
Solutions
- Read the wrapped API error for the precise rejection reason
- Verify machine type availability in the zone and that referenced network/IP/subnet resources exist
- Resolve quota or permission issues in the project, then re-run apply
Defensive patterns
Strategy: try-catch
When it happens
Trigger: Thrown at upup/pkg/fi/cloudup/gcetasks/instance.go:331 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of kubernetes/kops@4c8573c808 (2026-09-05).
Data as JSON: /api/errors/4eb51b3283ed969e.
Report an issue: GitHub.