kubernetes/kops · error
found multiple utility subnets in zone: %q
Error message
found multiple utility subnets in zone: %q
What it means
More than one Utility subnet is defined in the same availability zone; the AWS model builder supports at most one utility subnet per zone (a noted TODO) and cannot choose between duplicates.
Source
Thrown at pkg/model/awsmodel/context.go:78
func (b *AWSModelContext) LinkToUtilitySubnetInZone(zoneName string) (*awstasks.Subnet, error) {
var matches []*kops.ClusterSubnetSpec
for i := range b.Cluster.Spec.Networking.Subnets {
s := &b.Cluster.Spec.Networking.Subnets[i]
if s.Zone != zoneName {
continue
}
if s.Type != kops.SubnetTypeUtility {
continue
}
matches = append(matches, s)
}
if len(matches) == 0 {
return nil, fmt.Errorf("could not find utility subnet in zone: %q", zoneName)
}
if len(matches) > 1 {
// TODO: Support this
return nil, fmt.Errorf("found multiple utility subnets in zone: %q", zoneName)
}
return b.LinkToSubnet(matches[0]), nil
}
func (b *AWSModelContext) LinkToPrivateSubnetsInZone(zoneName string) ([]*awstasks.Subnet, error) {
var matches []*kops.ClusterSubnetSpec
for i := range b.Cluster.Spec.Networking.Subnets {
s := &b.Cluster.Spec.Networking.Subnets[i]
if s.Zone != zoneName {
continue
}
if s.Type != kops.SubnetTypePrivate {
continue
}
matches = append(matches, s)
}
if len(matches) == 0 {
return nil, fmt.Errorf("could not find private subnet in zone: %q", zoneName)View on GitHub (pinned to 4c8573c808)
Solutions
- Consolidate to a single utility subnet per zone in the cluster spec
- Remove or retype the duplicate utility subnet entries
- Re-run kops update
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at pkg/model/awsmodel/context.go:78 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/d591ae6044a9b3f1.
Report an issue: GitHub.