We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 501f7de commit c63b6a7Copy full SHA for c63b6a7
1 file changed
oracle/oracle.go
@@ -331,12 +331,14 @@ func (o *oracleOps) DeviceMappings() (map[string]string, error) {
331
return m, err
332
}
333
for _, va := range volumeAttachmentResp.Items {
334
- if va.GetDevice() != nil && va.GetVolumeId() != nil {
335
- devicePath = *va.GetDevice()
336
- volID = *va.GetVolumeId()
337
- } else {
338
- logrus.Warnf("Device path or volume id for [%+v] volume attachment not found", va)
339
- continue
+ if va.GetLifecycleState() == core.VolumeAttachmentLifecycleStateAttached {
+ if va.GetDevice() != nil && va.GetVolumeId() != nil {
+ devicePath = *va.GetDevice()
+ volID = *va.GetVolumeId()
+ } else {
+ logrus.Warnf("Device path or volume id for [%+v] volume attachment not found", va)
340
+ continue
341
+ }
342
343
m[devicePath] = volID
344
0 commit comments