kubernetes/kops · error
error modifying AssignIPv6AddressOnCreation: %w
Error message
error modifying AssignIPv6AddressOnCreation: %w
What it means
ModifySubnetAttribute failed while toggling AssignIpv6AddressOnCreation on the subnet; the wrapped error is the AWS EC2 response (permissions or subnet state).
Source
Thrown at upup/pkg/fi/cloudup/awstasks/subnet.go:308
Ipv6CidrBlock: e.IPv6CIDR,
SubnetId: e.ID,
}
_, err := t.Cloud.EC2().AssociateSubnetCidrBlock(ctx, request)
if err != nil {
return fmt.Errorf("error associating subnet cidr block: %v", err)
}
}
}
if a == nil || changes.AssignIPv6AddressOnCreation != nil {
request := &ec2.ModifySubnetAttributeInput{
SubnetId: e.ID,
AssignIpv6AddressOnCreation: &ec2types.AttributeBooleanValue{Value: e.AssignIPv6AddressOnCreation},
}
_, err := t.Cloud.EC2().ModifySubnetAttribute(ctx, request)
if err != nil {
return fmt.Errorf("error modifying AssignIPv6AddressOnCreation: %w", err)
}
}
if changes.ResourceBasedNaming != nil {
hostnameType := ec2types.HostnameTypeIpName
if *changes.ResourceBasedNaming {
hostnameType = ec2types.HostnameTypeResourceName
}
request := &ec2.ModifySubnetAttributeInput{
SubnetId: e.ID,
PrivateDnsHostnameTypeOnLaunch: hostnameType,
}
_, err := t.Cloud.EC2().ModifySubnetAttribute(ctx, request)
if err != nil {
return fmt.Errorf("error modifying hostname type: %w", err)
}
if fi.ValueOf(e.CIDR) == "" {View on GitHub (pinned to 4c8573c808)
Solutions
- Check ec2:ModifySubnetAttribute permissions
- Verify the subnet exists and is in a modifiable state, then retry
Defensive patterns
Strategy: try-catch
When it happens
Trigger: Thrown at upup/pkg/fi/cloudup/awstasks/subnet.go:308 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/e2fb5b672449c591.
Report an issue: GitHub.