kubernetes/kops · error
error listing volumes: %v
Error message
error listing volumes: %v
What it means
The EBSVolume task's Find() calls EC2 DescribeVolumes with name-tag filters and this error wraps any API failure from that call. It means kOps could not enumerate the volumes, so reconciliation cannot compare actual vs desired state. The wrapped AWS error carries the true cause.
Source
Thrown at upup/pkg/fi/cloudup/awstasks/ebsvolume.go:68
var _ fi.CompareWithID = (*EBSVolume)(nil)
var _ fi.CloudupTaskNormalize = (*EBSVolume)(nil)
func (e *EBSVolume) CompareWithID() *string {
return e.ID
}
func (e *EBSVolume) Find(c *fi.CloudupContext) (*EBSVolume, error) {
ctx := c.Context()
cloud := awsup.GetCloud(c)
filters := cloud.BuildFilters(e.Name)
request := &ec2.DescribeVolumesInput{
Filters: filters,
}
response, err := cloud.EC2().DescribeVolumes(ctx, request)
if err != nil {
return nil, fmt.Errorf("error listing volumes: %v", err)
}
if response == nil || len(response.Volumes) == 0 {
return nil, nil
}
if len(response.Volumes) != 1 {
return nil, fmt.Errorf("found multiple Volumes with name: %s", *e.Name)
}
klog.V(2).Info("found existing volume")
v := response.Volumes[0]
actual := &EBSVolume{
ID: v.VolumeId,
AvailabilityZone: v.AvailabilityZone,
VolumeType: v.VolumeType,
SizeGB: v.Size,
KmsKeyId: v.KmsKeyId,
Encrypted: v.Encrypted,View on GitHub (pinned to 4c8573c808)
Solutions
- Grant ec2:DescribeVolumes in the IAM policy
- Inspect the wrapped %v error for throttling and retry with backoff
- Verify AWS credentials/region configuration
- Reduce call frequency if hitting API limits
Defensive patterns
Strategy: retry
Validate before calling
// Validate credentials and permission up front
_, err := iamSimulatePrincipalPolicy(iamClient, &iamsim.SimulatePrincipalPolicyInput{
PolicySourceArn: aws.String(roleArn),
ActionNames: []string{"ec2:DescribeVolumes"},
}) Try / catch
resp, err := cloud.EC2().DescribeVolumes(ctx, request)
if err != nil {
var terr *ec2types.ThrottlingException
if errors.As(err, &terr) { /* backoff and retry */ }
return fmt.Errorf("error listing volumes: %w", err)
} Prevention
- Include ec2:DescribeVolumes in kOps IAM policy
- Implement exponential backoff for AWS throttling errors
- Validate AWS credentials/region before update runs
When it happens
Trigger: DescribeVolumes call in Find() fails — invalid filter syntax, missing ec2:DescribeVolumes permission, throttling, or connectivity/credential issues against AWS.
Common situations: IAM credentials without ec2:DescribeVolumes; AWS API rate limiting on large accounts; expired or misconfigured credentials during `kops update cluster --yes`.
Related errors
- error deleting Volume %q: %v
- error describing volumes: %v
- found multiple Volumes with name: %s
- error creating PersistentVolume: %v
- error adding AWS Tags to EBS Volume: %v
AI-assisted analysis of kubernetes/kops@4c8573c808 (2026-09-05).
Data as JSON: /api/errors/92ae6ae34bc2ffa4.
Report an issue: GitHub.