Ask Your Question
0

Openstack pike: No valid host was found. There are not enough hosts available. - code 500

asked 2018-03-13 04:52:53 -0600

Regex gravatar image

I have setup a multi nodes Openstack env using tripleO for a PoC. The environment consists of (Running on baremetal):

1- Undercloud
2- Overcloud:
        -Controller
        -Compute-0
        -Compute-1

I have created a few instances and everything is fine but now I'm not able to create any new instance. I have checked the compute resources and they are plenty. I'm using cinder for both storing the instances and images.

 (overcloud) [heat-admin@overcloud-controller-0 ~]$ openstack compute service list
+----+------------------+---------------------------------+-----------+---------+-------+----------------------------+
| ID | Binary           | Host                            | Zone      | Status  | State | Updated At                 |
+----+------------------+---------------------------------+-----------+---------+-------+----------------------------+
|  4 | nova-conductor   | overcloud-controller-0.lab.poc  | internal  | enabled | up    | 2018-03-13T08:50:50.000000 |
| 18 | nova-compute     | overcloud-novacompute-1.lab.poc | compute-1 | enabled | up    | 2018-03-13T08:50:49.000000 |
| 19 | nova-consoleauth | overcloud-controller-0.lab.poc  | internal  | enabled | up    | 2018-03-13T08:50:47.000000 |
| 20 | nova-scheduler   | overcloud-controller-0.lab.poc  | internal  | enabled | up    | 2018-03-13T08:50:51.000000 |
| 21 | nova-compute     | overcloud-novacompute-0.lab.poc | compute-0 | enabled | up    | 2018-03-13T08:50:50.000000 |
+----+------------------+---------------------------------+-----------+---------+-------+----------------------------+
nova-conductor.log (debug enabled):
 2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager [req-c982618d-c1c0-46f1-9182-3e542f5af8af 5c1e3b2d8bc44ca08d3ccfe9c2a6ff17 7e66bf9554f748018600d046f22acc16 - default default] Failed to schedule instances: NoValidHost_Remote: No valid host was found. There are not enough hosts available. There are not enough hosts available.
Traceback (most recent call last):

  File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/server.py", line 232, in inner
    return func(*args, **kwargs)

  File "/usr/lib/python2.7/site-packages/nova/scheduler/manager.py", line 149, in select_destinations
    alloc_reqs_by_rp_uuid, provider_summaries)

  File "/usr/lib/python2.7/site-packages/nova/scheduler/filter_scheduler.py", line 110, in select_destinations
    raise exception.NoValidHost(reason=reason)

NoValidHost: No valid host was found. There are not enough hosts available.
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager Traceback (most recent call last):
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager   File "/usr/lib/python2.7/site-packages/nova/conductor/manager.py", line 1036, in schedule_and_build_instances
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager     instance_uuids)
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager   File "/usr/lib/python2.7/site-packages/nova/conductor/manager.py", line 626, in _schedule_instances
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager     request_spec, instance_uuids)
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager   File "/usr/lib/python2.7/site-packages/nova/scheduler/utils.py", line 586, in wrapped
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager     return func(*args, **kwargs)
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager   File "/usr/lib/python2.7/site-packages/nova/scheduler/client/__init__.py", line 52, in select_destinations
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager     instance_uuids)
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager   File "/usr/lib/python2.7/site-packages/nova/scheduler/client/__init__.py", line 37, in __run_method
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager     return getattr(self.instance, __name)(*args, **kwargs)
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager   File "/usr/lib/python2.7/site-packages/nova/scheduler/client/query.py", line 33, in select_destinations
2018-03-13 07:13:52.676 3840 ERROR nova.conductor.manager     instance_uuids)
2018-03-13 07:13:52.676 3840 ERROR ...
(more)
edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
0

answered 2018-03-13 14:14:31 -0600

Regex gravatar image

After spending so much time, i found the exact issue and it turns out that the disk size used for filtering is wrong because whenever you create an instance, it thinks that you use the local disk and it adds that size to the total disk size (in case you use external storage for cinder).

I found a workaround for now, which is to create a new flavor with the root disk space set to '0' .

edit flag offensive delete link more

Comments

HI,

I am also getting the sam error in Openstack Queen. I am creating the first instance with cirrios image that comes by default. I have 1.6TB of disk and 54GB ram and 16 CPU. but the smalles instance also is giving the problem.

I am using the local disk and not the storage. Kindly suggest.

gaurav.mittal gravatar imagegaurav.mittal ( 2018-07-06 00:09:10 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2018-03-13 03:57:13 -0600

Seen: 1,447 times

Last updated: Mar 13