-
Notifications
You must be signed in to change notification settings - Fork 40
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
fix empty volume group creation through cli tool #767
fix empty volume group creation through cli tool #767
Conversation
088819c
to
4409e17
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @Nikhil-Ladha, the change looks good to me.
Can you explain a little more about the csi panics? Is there a particular CSI driver that has a problem with an empty volume-id? If so, please report that as a bug against the driver too.
The rbd ceph-csi driver panics when I try to create the VolumeGroup though CLI with an empty volumeid list. The following is the error on CLI:
And, the below is the csi-rbdplugin container logs:
Notice the |
when creating empty volume group through cli, the strings.Split() function returns a [""] value, i.e, a slice of length 1 having the value as 1 `[""]` empty string. As a result, csi panics when it tries to find the volumeID with the respective value. Signed-off-by: Nikhil-Ladha <nikhilladha1999@gmail.com>
4409e17
to
db71f1b
Compare
This code seems to return an error when the volume-id can not be found. I do not think there is a bug in the current Ceph-CSI implementation for this. You seem to have a different/modified version (line numbers do not match or exist ( It should be safe to pass an empty volume-id to any Ceph-CSI gRPC procedures, and Ceph-CSI should definitely not crash. If you hit such a problem, please create an issue against Ceph-CSI for that. Thank! |
Yeah, I have few changes included for VGR testing.
It is safe to pass an empty id, and with this change that is verified. |
when creating empty volume group through cli, the strings.Split() function returns a [""] value, i.e, a slice of length 1 having the value as 1 (
[""]
) empty string. As a result, the csi panics when it tries to find the volumeID with the respective value.