-
Notifications
You must be signed in to change notification settings - Fork 253
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
Compute AZs should not be used as Volume AZs #1649
Comments
Before #1030 we let Nova create the root volume for us. I'm pretty sure my intention at the time was to copy the behaviour of Nova to minimise the change involved, so I certainly believed that Nova would explicitly request a cinder volume in an AZ with the same name as the Nova AZ if a Nova AZ was given. I can't remember how deeply I checked that at the time, though. However, there's no reason we can't change it now. I believe it would be a breaking API change, so if we think this is important to change let prioritise it so we get it in before v1beta1. We could do something like this in the current version: rootVolume:
size: 50
ignoreMachineAZ: true In the next version we could flip the default and add: rootVolume:
size: 50
useMachineAZ: true |
I think we could be even simpler than this. On up-conversion, if the AZ was not previously given we hydrate it to... we can't do that because the AZ is in the Machine object not the OpenStackMachine object, so isn't available during conversion :( As you were. |
I thought the same until I went and investigated. It turns out this is the behaviour of Nova but only if
Sounds like we have a strategy going forward so. Hurrah! |
/assign EmilienM |
/unassign Emilien |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
/remove-lifecycle stale |
To be clear: the missing feature here is the ability to specify use cinder's default. It is missing because we always default root volume AZ to be the same as the machine AZ if it is not given, which is not always correct. We don't want to have to specify cinder's default, because then we wouldn't be using the default. The question is which case do we want to 'optimise' for: the case where they are the same, or the case where they are not. i.e. Which should the default be? Note that the following is not an option: rootVolume:
...
availabilityZone: <explicitly put machine AZ here> the reason being that CAPI can vary the control plane machines' failure domains, so we can't hardcode it in the machine spec. How about we added the following to RootVolume: AvailabilityZone: string,
// +required
// default=RootVolume
AvailabilityZoneSource: AvailabilityZoneSourceType, AvailabilityZoneSourceType can be 'RootVolume', 'Machine', or 'Cinder'. It defaults to 'RootVolume' if AvailabilityZone is set on creation, and 'Machine' if it is not, which preserves the current behaviour. Setting it explicitly to 'Cinder' allows the Cinder default AZ to be used. I don't know if that defaulting is possible without a mutating webhook, btw. I'd have to investigate. It's probably not too complex even if the webhook is required. With the above: Uses Machine AZ: rootVolume:
... (no AZ) Uses explicit AZ: rootVolume:
...
availabilityZone: my_custom_az Both of the above preserve the existing behaviour for the same input. The new behaviour is: rootVolume:
...
availabilityZoneSource: Cinder This uses the Cinder default, which was not previously possible. In all cases, the relevant availabilityZoneSource would always be added to the object on creation, so it would always be immediately apparent when fetching the object which AZ was in use. |
Actually, written this way this would be a backwards compatible change. This might not be a rush for v1beta1 after all. |
Where would it be defined, or how would we figured this one out? |
It would be defined in Cinder. We would not specify any value. The API problem we have here is that 'no value' has 2 possible resolutions:
We can currently do the former, but not the latter. |
/kind feature
Describe the solution you'd like
In #1030, we added support for defining root volume AZs, closing #1021. When this was implemented, a decision was made to use the MachineSpec's
failureDomain
attribute to populaterootVolume.availabilityZone
if the latter was not configured. This feels like an anti-pattern. Compute AZs are not Volume AZs, and while they may be identical in smaller, simpler deployments with a single AZ (Cinder's default AZ isnova
to allow this) or hyper-converged deployments, wherenova-compute
andcinder-volume
run side-by-side on hosts, it's unlikely to be the case elsewhere. I've seen this pop up already in different deployments.Is there any reason why we can't default to no implicit AZ or at least validate the implicit AZ exists?
Anything else you would like to add:
I'm not sure if this change in behavior would need to be placed behind an API version or not. Would welcome input in any case.
The text was updated successfully, but these errors were encountered: