Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dynamic Provisioning with Topology Awareness Support #17

Closed
leakingtapan opened this issue Sep 25, 2018 · 3 comments
Closed

Dynamic Provisioning with Topology Awareness Support #17

leakingtapan opened this issue Sep 25, 2018 · 3 comments
Assignees
Milestone

Comments

@leakingtapan
Copy link
Contributor

leakingtapan commented Sep 25, 2018

Currently, AWS cloud interface used by EBS CSI controller service is instantiated with the same AZ as where controller service is running. This causes the issue that EBS volume is only created at the AZ where controller service runs.

For example, if there are three nodes, each in us-west-2a, us-west-2b and us-west-2c. And controller service runs in us-west-2b while application is deployed to us-west-2a. During volume creation, the new volume will always be created in us-west-2b which causes application deployment to fail (since EBS volume and instance have to be in the same AZ).

One way to fix this is using node selector to always deploy application in the same AZ as controller. Or use static provision where PV/PVC created statically. However, both approach is non-ideal. They either enforces where controller service can run or invalidates the use case of dynamic provisioning.

@ddebroy
Copy link

ddebroy commented Sep 26, 2018

For Kubernetes, You will want to integrate with the topology awareness framework in kubernetes-csi/external-provisioner#141 in Kube-CSI. This will make sure CreateVolumeRequest passed down has a reference to the SelectedNode chosen for a pod where a volume needs to be provisioned when WaitForFirstConsumer is set. The AZ of the SelectedNode can be used to perform the AWS Cloud API calls to make sure the volume is provisioned in the same AZ as the SelectedNode for the pod. This will ensure parity wrt topology/zone awareness the in-tree EBS driver.

@leakingtapan leakingtapan added this to the 0.3-alpha milestone Sep 26, 2018
@leakingtapan leakingtapan added the kind/bug Categorizes issue or PR as related to a bug. label Sep 26, 2018
@leakingtapan leakingtapan changed the title [Bug] Controller Service uses node AZ to create volume Controller Service uses node AZ to create volume Sep 26, 2018
@leakingtapan
Copy link
Contributor Author

@ddebroy thanks for the input. Will take a look at topology awareness framework.

@leakingtapan leakingtapan removed the kind/bug Categorizes issue or PR as related to a bug. label Sep 27, 2018
@leakingtapan leakingtapan modified the milestones: 0.3-alpha, 0.3-beta Sep 27, 2018
@leakingtapan leakingtapan changed the title Controller Service uses node AZ to create volume Dynamic Provisioning with Topology Awareness Support Oct 2, 2018
@leakingtapan leakingtapan self-assigned this Oct 4, 2018
@leakingtapan
Copy link
Contributor Author

Researched how to leverage topology awareness for volume provisioning. Since we can safely assume EBS has only one topology key which is zone, the work requires for this feature will be:

  • return topology in NodeGetInfo response eg. accessible_topology = {"zone": "us-west-2a"}
  • consume topology requirement in CreateVolume request and creates volume using the given zone

Working on implementing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants