Insufficient error handling when parsing iscsiadm -m node output with blank iscsi target
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Fix Committed
|
Medium
|
Unassigned | ||
os-brick |
Fix Committed
|
Medium
|
Unassigned |
Bug Description
We encountered the following error when attempting to reboot a VM with multiple attached volumes -
2020-07-02 05:46:05.960 ERROR oslo_messaging.
...
2020-07-02 05:46:05.960 TRACE oslo_messaging.
2020-07-02 05:46:05.960 TRACE oslo_messaging.
2020-07-02 05:46:05.960 TRACE oslo_messaging.
This is observed on os-brick version - 1.15.9
The same code in current master branch -
https:/
iscsiadm -m node output -
172.30.
172.30.
172.30.
[]:3260,-1
172.30.
172.30.
172.30.
The blank target causes an unhandled exception. A simple python code snippet to show the same -
>>> out = "172.30.
>>> lines = []
>>> out.splitlines()
['172.30.
>>> for line in out.splitlines():
... if line:
... info = line.split()
... lines.append(
...
Traceback (most recent call last):
File "<stdin>", line 4, in <module>
The blank iscsi target was most probably due to corruption of the iscsi data during discovery.
Using strace we could trace that blank target belongs to a OpenStack volume -
open("/
Expected:
Management of that single volume associated with blank iscsi target to be affected.
Observed:
None of the volumes and volume backed VMs can be managed on the affected host.
no longer affects: | nova |
Changed in os-brick: | |
status: | New → Fix Committed |
importance: | Undecided → Medium |
Changed in cinder: | |
importance: | Undecided → Medium |
status: | New → Fix Committed |
tags: | added: iscsiadm |
Is there a way to handle blank iscsi target files gracefully?