+++ This bug was initially created as a clone of Bug #1080622 +++ Description of problem: If the number of datastores is greater than the maximum, the PropertyCollector returns a token value that should be used to iterate over the entire result set. The get_datastore_ref_and_name function in vm_util.py is aware of tokens but it stops on the first found datastore (line 942) instead searching for the best match over the entire set. We should improve get_datastore_ref_and_name to: 1) clearly specify how the datastore is selected (the current pydoc is wrong) 2) select the best match by iterating the whole result set
I am not sure I did correct test: I have set the `maximum_objects=1` in nova.conf and I was then changing the datastore_regex= to select the datastore. I have two datastores and this way, I was able to select the one the VM should be booted on.
(In reply to Jaroslav Henner from comment #5) > I am not sure I did correct test: > I have set the `maximum_objects=1` in nova.conf and I was then changing the > datastore_regex= to select the datastore. I have two datastores and this > way, I was able to select the one the VM should be booted on. yaniv, can you help out here?
(In reply to Jaroslav Henner from comment #5) > I am not sure I did correct test: > I have set the `maximum_objects=1` in nova.conf and I was then changing the > datastore_regex= to select the datastore. I have two datastores and this > way, I was able to select the one the VM should be booted on. I've looked at the code, and this looks like a valid test to me.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHSA-2014-1084.html