kubernetes/kops · error

error listing InstanceGroupManagers: %v

Error message

error listing InstanceGroupManagers: %v

What it means

Wrapped error from InstanceGroupManager.Find when the InstanceGroupManagers.Get call fails with a non-404 error. Misleadingly worded as 'listing'; it actually indicates a failed single-resource Get during cloud discovery (permissions, wrong zone, API failure).

Source

Thrown at upup/pkg/fi/cloudup/gcetasks/instancegroupmanager.go:59

	TargetPools []*TargetPool
}

var _ fi.CompareWithID = (*InstanceGroupManager)(nil)

func (e *InstanceGroupManager) CompareWithID() *string {
	return e.Name
}

func (e *InstanceGroupManager) Find(c *fi.CloudupContext) (*InstanceGroupManager, error) {
	cloud := c.T.Cloud.(gce.GCECloud)

	r, err := cloud.Compute().InstanceGroupManagers().Get(cloud.Project(), *e.Zone, *e.Name)
	if err != nil {
		if gce.IsNotFound(err) {
			return nil, nil
		}
		return nil, fmt.Errorf("error listing InstanceGroupManagers: %v", err)
	}

	actual := &InstanceGroupManager{}
	actual.Name = &r.Name
	actual.Zone = new(lastComponent(r.Zone))
	actual.BaseInstanceName = &r.BaseInstanceName
	actual.TargetSize = e.TargetSize
	actual.InstanceTemplate = &InstanceTemplate{ID: new(lastComponent(r.InstanceTemplate))}
	actual.ListManagedInstancesResults = r.ListManagedInstancesResults

	if policy := r.UpdatePolicy; policy != nil {
		actual.UpdatePolicy = &UpdatePolicy{MinimalAction: policy.MinimalAction, Type: policy.Type}
	}

	for _, targetPool := range r.TargetPools {
		actual.TargetPools = append(actual.TargetPools, &TargetPool{
			Name: new(lastComponent(targetPool)),
		})

View on GitHub (pinned to 4c8573c808)

Solutions

  1. Check the wrapped error for the Google API failure reason
  2. Confirm the IGM name and zone are correct in the spec
  3. Ensure compute.instanceGroupManagers.get permission for the service account
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at upup/pkg/fi/cloudup/gcetasks/instancegroupmanager.go:59 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/28040de07c087f2b. Report an issue: GitHub.