kubernetes/kops · error

deleting droplets is not supported yet

Error message

deleting droplets is not supported yet

What it means

Droplet RenderDO supports only scaling a droplet instance group up. Once actualCount exceeds expectedCount (i.e., a droplet needs to be deleted to converge), the task refuses since droplet-based (non-VMSS/autoscaled) scale-down is not implemented in kops.

Source

Thrown at upup/pkg/fi/cloudup/dotasks/droplet.go:149

	userData, err := fi.ResourceAsString(e.UserData)
	if err != nil {
		return err
	}

	var newDropletCount int
	if a == nil {
		newDropletCount = e.Count
	} else {

		expectedCount := e.Count
		actualCount := a.Count

		if expectedCount == actualCount {
			return nil
		}

		if actualCount > expectedCount {
			return errors.New("deleting droplets is not supported yet")
		}

		newDropletCount = expectedCount - actualCount
	}

	// associate vpcuuid to the droplet if set.
	vpcUUID := ""
	if fi.ValueOf(e.NetworkCIDR) != "" {
		s, err := t.Cloud.GetVPCUUID(fi.ValueOf(e.NetworkCIDR), fi.ValueOf(e.VPCName))
		if err != nil {
			return fmt.Errorf("fetching vpcUUID from network cidr=%s: %w", fi.ValueOf(e.NetworkCIDR), err)
		}
		vpcUUID = s
	} else if fi.ValueOf(e.VPCUUID) != "" {
		vpcUUID = fi.ValueOf(e.VPCUUID)
	}

	for i := 0; i < newDropletCount; i++ {

View on GitHub (pinned to 4c8573c808)

Solutions

  1. Manually delete the surplus droplets in the DigitalOcean console or via doctl compute droplet delete, then re-run kops update
  2. Use a VMSS-style autoscaling group (DigitalOcean load-balancer backed group) instead of raw droplets for scalable groups
  3. Increase expectedCount back to match reality if the shrink was unintentional
  4. Implement scale-down in RenderDO (delete oldest droplets, then remove from LB) if maintaining a fork

Example fix

// before: shrink in spec triggers the error
instanceCount: 3 -> 2
// after: delete the droplet manually first
doctl compute droplet delete <droplet-id>
# then apply the new instanceCount
Defensive patterns

Strategy: validation

Validate before calling

if desiredCount < actualCount && isDropletGroup {
	return errors.New("scale-down of droplet groups unsupported; delete droplets manually first")
}

Try / catch

if err := task.RenderDO(ctx, target, a, e); err != nil {
	if strings.Contains(err.Error(), "deleting droplets is not supported yet") {
		// delete surplus droplets via doctl/API, then re-run
	} else { return err }
}

Prevention

When it happens

Trigger: kops update cluster or rolling-update on DigitalOcean when a droplet instance group's instanceCount was lowered (or machines were removed from the spec) so existing droplets must be terminated.

Common situations: Reducing the size of a droplet instance group in the cluster spec; replacing droplets after a spec change; manually created extra droplets making actualCount > expectedCount during convergence.

Related errors


AI-assisted analysis of kubernetes/kops@4c8573c808 (2026-09-05). Data as JSON: /api/errors/8581a6f5abe28381. Report an issue: GitHub.