You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Null variable backtrace when attempting to mount a volume as opposed to an error describing the issue.
Environment details
Image/version of Ceph CSI driver : origin/release-v3.11
Mounter used for mounting PVC (for cephFS its fuse or kernel. for rbd its krbd or rbd-nbd) : rbd
Steps to reproduce
Steps to reproduce the behavior:
Cause a reason for the mount to fail, for instance, not being able to connect to ceph
Observe bad error message.
Actual results
Expected behavior
The snippet below is from internal/rbd/nodeserver.go. When an error occurs variable rv is NULL, and thus the rv.Destroy() call can't possibly work. The code should check if rv is Null first and then do an rv.Destroy().
It seems possible that the .Destroy() function is called on a nil
pointer. This would cause a panic in the node-plugin.
Depending on how far GenVolFromVolID() comes, the returned rbdVolume can
be connected. If an error occurs, the rbdVolume should not be connected
at all, so call the .Destroy() function in those cases too.
Fixes: ceph#4562
Signed-off-by: Niels de Vos <ndevos@ibm.com>
Describe the bug
Null variable backtrace when attempting to mount a volume as opposed to an error describing the issue.
Environment details
Image/version of Ceph CSI driver : origin/release-v3.11
Mounter used for mounting PVC (for cephFS its
fuse
orkernel
. for rbd itskrbd
orrbd-nbd
) : rbdSteps to reproduce
Steps to reproduce the behavior:
Actual results
Expected behavior
The snippet below is from internal/rbd/nodeserver.go. When an error occurs variable rv is NULL, and thus the rv.Destroy() call can't possibly work. The code should check if rv is Null first and then do an rv.Destroy().
Logs
Additional context
Add any other context about the problem here.
For example:
Any existing bug report which describe about the similar issue/behavior
The text was updated successfully, but these errors were encountered: