Race condition in handling of udev generated symlinks
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Invalid
|
Low
|
Unassigned | ||
OpenStack Compute (nova) |
Opinion
|
Low
|
Unassigned |
Bug Description
In several components in both Cinder and Nova udev provided symlinks are expected to appear immediately.
This is not the case as udev rules run async of device plugging.
Volume drivers in Cinder and the libvirt driver in Nova seem to be the primary culprits.
To solve this we should wait for udevd to finish processing events, this can be done with udevadm by calling settle. This is done by simply calling "udevadm settle". Additionally it can be called with a timeout (probably a good idea).
Excerpt from udevadm settle --help:
Usage: udevadm settle OPTIONS
--timeout=
--seq-
--seq-
--exit-
--quiet do not print list after timeout
--help
For more intelligent use we could wrap this in a function that can use the --exit-if-exists behavior.
This will ensure the symlink actually exists before we try use it.
description: | updated |
Changed in cinder: | |
status: | New → Triaged |
importance: | Undecided → Low |
milestone: | none → havana-1 |
Changed in cinder: | |
assignee: | nobody → David Medberry (med) |
Changed in nova: | |
assignee: | nobody → David Medberry (med) |
Changed in cinder: | |
milestone: | havana-1 → havana-2 |
Changed in cinder: | |
milestone: | havana-2 → havana-3 |
Changed in cinder: | |
assignee: | David Medberry (med) → nobody |
milestone: | havana-3 → none |
Changed in nova: | |
assignee: | David Medberry (med) → nobody |
Changed in cinder: | |
status: | Triaged → Incomplete |
status: | Incomplete → Invalid |
good suggestion. This might allow us to remove some of the retrys that we use.