mirror of https://github.com/k3s-io/k3s
Merge pull request #61082 from wenlxie/githubupstream.master.ignorevolumeerrorstatus
Automatic merge from submit-queue (batch tested with PRs 61549, 62230, 62055, 61082, 62212). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. don't do attach and deatch when cinder volume status is error When cinder volume status is `error`, it is not supposed to handle operation like `attach` and `detach` @dims @FengyunPan2 ```release-note cinder volume plugin : When the cinder volume status is `error`, controller will not do `attach ` and `detach ` operation ```pull/8/head
commit
27045d3fcd
|
@ -310,7 +310,8 @@ func (os *OpenStack) OperationPending(diskName string) (bool, string, error) {
|
|||
}
|
||||
volumeStatus := volume.Status
|
||||
if volumeStatus == volumeErrorStatus {
|
||||
return false, volumeStatus, nil
|
||||
err = fmt.Errorf("status of volume %s is %s", diskName, volumeStatus)
|
||||
return false, volumeStatus, err
|
||||
}
|
||||
if volumeStatus == volumeAvailableStatus || volumeStatus == volumeInUseStatus || volumeStatus == volumeDeletedStatus {
|
||||
return false, volume.Status, nil
|
||||
|
|
Loading…
Reference in New Issue