kubernetes/kops · error
error listing Akamai (Linode) interfaces for instance %s(%d)
Error message
error listing Akamai (Linode) interfaces for instance %s(%d): %w
What it means
instanceSubnetBlocks in kOps' Akamai (Linode) code lists a Linode instance's network interfaces to extract VPC subnet blocks. This error wraps a ListInterfaces failure, identifying the instance by label and numeric ID, and aborts listInstances (so instance discovery fails).
Source
Thrown at pkg/resources/linode/resources.go:144
Name: volume.Label,
ID: strconv.Itoa(volume.ID),
Type: resourceTypeVolume,
Deleter: deleteVolume,
Obj: volume,
}
if volume.LinodeID != nil {
resourceTracker.Blocked = []string{resourceTypeInstance + ":" + strconv.Itoa(*volume.LinodeID)}
}
resourceTrackers = append(resourceTrackers, resourceTracker)
}
return resourceTrackers, nil
}
func instanceSubnetBlocks(cloud cloudlinode.LinodeCloud, instance linodego.Instance) ([]string, error) {
interfaces, err := cloud.Client().ListInterfaces(context.Background(), instance.ID, nil)
if err != nil {
return nil, fmt.Errorf("error listing Akamai (Linode) interfaces for instance %s(%d): %w", instance.Label, instance.ID, err)
}
blockSet := make(map[string]struct{})
for _, iface := range interfaces {
if iface.VPC == nil {
continue
}
blockSet[resourceTypeSubnet+":"+strconv.Itoa(iface.VPC.SubnetID)] = struct{}{}
}
blocks := make([]string, 0, len(blockSet))
for block := range blockSet {
blocks = append(blocks, block)
}
sort.Strings(blocks)
return blocks, nil
}View on GitHub (pinned to 4c8573c808)
Solutions
- Verify the Linode token includes VPC/network interface read permissions.
- If the wrapped error is 404, the instance vanished mid-listing — rerun; the refreshed instance list will exclude it.
- Reduce concurrency or retry after the rate-limit window.
- Check Linode API availability, then rerun `kops delete cluster` / dump.
Defensive patterns
Strategy: try-catch
Validate before calling
// confirm instance still exists before listing its interfaces
inst, err := c.Client().GetInstance(ctx, instance.ID)
if err != nil || inst == nil {
return nil // instance gone; nothing to enumerate
} Type guard
func isLinodeNotFound(err error) bool {
var le linodego.Error
return errors.As(err, &le) && le.Code == 404
} Try / catch
ifaces, err := cloud.Client().ListInterfaces(ctx, instance.ID, nil)
if err != nil {
if isLinodeNotFound(err) {
return nil, nil // deleted concurrently; skip
}
return nil, fmt.Errorf("error listing Akamai (Linode) interfaces for instance %s(%d): %w", instance.Label, instance.ID, err)
} Prevention
- Avoid concurrent manual deletion of Linode instances while kOps enumerates resources.
- Ensure the token has VPC/interface read scope (older tokens may not).
- Treat 404s as already-deleted rather than fatal.
- Rate-limit interface listing when many instances are present.
When it happens
Trigger: cloud.Client().ListInterfaces(ctx, instance.ID, nil) errors: token lacks VPC/interface read scopes, instance deleted between listing and interface fetch (404), rate limit, or API outage.
Common situations: Concurrent teardown deleting the instance while ListInterfaces is in flight; older API tokens without VPC permissions; heavy delete loops hitting Linode rate limits.
Related errors
- error listing Akamai (Linode) instances: %w
- error listing Akamai (Linode) volumes: %w
- error listing Akamai (Linode) VPCs: %w
- error parsing Akamai (Linode) %s ID %q: %w
- error listing Akamai (Linode) SSH keys: %w
AI-assisted analysis of kubernetes/kops@4c8573c808 (2026-09-05).
Data as JSON: /api/errors/c04504c738f10ea1.
Report an issue: GitHub.