question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Multiple default storageClasses when specifying storageClass in EKS cluster

See original GitHub issue

When creating an EKS cluster and specifying a custom storage class (e.g. st1), the default gp2 storageClass is created along side the custom st1 storageClass which is also marked as default.

Where storageClass = "st1":

const vpc = new awsx.ec2.Vpc("Kafka-VPC", {numberOfAvailabilityZones: 3});

// Create an EKS cluster with the given configuration.
const cluster = new eks.Cluster("kafka-cluster", {
    vpcId: vpc.id,
    subnetIds: vpc.privateSubnetIds,
    instanceType: instanceType,
    desiredCapacity: desiredCapacity,
    minSize: minSize,
    maxSize: maxSize,
    storageClasses: storageClass,
    deployDashboard: deployDashboard,
});

This results in:

NAME                                   PROVISIONER             AGE
gp2 (default)                          kubernetes.io/aws-ebs   23m
kafka-cluster-st1-evr2qvmh (default)   kubernetes.io/aws-ebs   21m

This can cause issues when helm charts rely on one default storage class since the storageClass name cannot be passed directly to the charts.

Expected behavior: One storageClass is marked as default after EKS creation (preferably the user specified class) Actual behavior: Both the EKS created gp2 AND the user specified st1 storage class are marked as default.

Other thoughts: Ability to add/remove default status to storageClasses

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:15 (10 by maintainers)

github_iconTop GitHub Comments

2reactions
metralcommented, Jul 1, 2019

#172 will close out this issue and #139, by supplying the exported names of all storage classes. This can then be used to pass into the Helm charts per the original use-case need.

0reactions
lukehobancommented, Jul 1, 2019

@metral What work is being tracked in this issue now?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Storage classes - Amazon EKS - AWS Documentation
You must define storage classes for your cluster to use and you should define a default storage class for your persistent volume claims....
Read more >
Change the default StorageClass | Kubernetes
This page shows how to change the default Storage Class that is used to provision volumes for PersistentVolumeClaims that have no special ...
Read more >
Storage classes - Amazon EKS - 亚马逊云科技
You must define storage classes for your cluster to use and you should define a default storage class for your persistent volume claims....
Read more >
Define Storageclass - Amazon EKS Workshop
The encrypted parameter will ensure the EBS volumes are encrypted by default. The volumeBindingMode is WaitForFirstConsumer to ensure persistent volume will be ...
Read more >
Dynamic Provisioning using Storage Classes - Hex Quote
When you have multiple storage classes, you can specify a default one ... I am using AWS EKS for kubernetes cluster and EBS...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found