Ask Your Question
1

No valid host was found. There are not enough hosts available.

asked 2016-09-17 07:15:26 -0500

lozzzzzer gravatar image

updated 2016-09-17 10:05:47 -0500

sunnyarora gravatar image

I'm a newbie to Openstack and trouble shooting this seem to be a dark art.

I built a Mitaka RDO one node env, everything was working then it just stopped allowing me to create instances...

I did run out of storage but after asking google I now have a 2TB NFS on /var/lib/nova/instances which seems of solved that problem...

Unfortunately this did not fix it.

No valid host was found. There are not enough hosts available.
Code
500
Details
File "/usr/lib/python2.7/site-packages/nova/conductor/manager.py", line 392, in build_instances context, request_spec, filter_properties) File "/usr/lib/python2.7/site-packages/nova/conductor/manager.py", line 436, in _schedule_instances hosts = self.scheduler_client.select_destinations(context, spec_obj) File "/usr/lib/python2.7/site-packages/nova/scheduler/utils.py", line 372, in wrapped return func(*args, **kwargs) File "/usr/lib/python2.7/site-packages/nova/scheduler/client/__init__.py", line 51, in select_destinations return self.queryclient.select_destinations(context, spec_obj) File "/usr/lib/python2.7/site-packages/nova/scheduler/client/__init__.py", line 37, in __run_method return getattr(self.instance, __name)(*args, **kwargs) File "/usr/lib/python2.7/site-packages/nova/scheduler/client/query.py", line 32, in select_destinations return self.scheduler_rpcapi.select_destinations(context, spec_obj) File "/usr/lib/python2.7/site-packages/nova/scheduler/rpcapi.py", line 121, in select_destinations return cctxt.call(ctxt, 'select_destinations', **msg_args) File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/client.py", line 158, in call retry=self.retry) File "/usr/lib/python2.7/site-packages/oslo_messaging/transport.py", line 90, in _send timeout=timeout, retry=retry) File "/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py", line 470, in send retry=retry) File "/usr/lib/python2.7/site-packages/oslo_messaging/_drivers/amqpdriver.py", line 461, in _send raise result
Created
17 Sep 2016, 10:58 a.m.

-

[root@localhost ~(keystone_admin)]# nova service-list
+----+------------------+-----------------------+----------+---------+-------+----------------------------+-----------------+
| Id | Binary           | Host                  | Zone     | Status  | State | Updated_at                 | Disabled Reason |
+----+------------------+-----------------------+----------+---------+-------+----------------------------+-----------------+
| 11 | nova-cert        | localhost.localdomain | internal | enabled | up    | 2016-09-17T12:12:06.000000 | -               |
| 12 | nova-consoleauth | localhost.localdomain | internal | enabled | up    | 2016-09-17T12:12:11.000000 | -               |
| 13 | nova-scheduler   | localhost.localdomain | internal | enabled | up    | 2016-09-17T12:12:05.000000 | -               |
| 14 | nova-conductor   | localhost.localdomain | internal | enabled | up    | 2016-09-17T12:12:10.000000 | -               |
| 15 | nova-compute     | localhost.localdomain | nova     | enabled | up    | 2016-09-17T12:12:06.000000 | -               |
+----+------------------+-----------------------+----------+-----

Not sure to start again?

Thanks

Andrew

edit retag flag offensive close merge delete

6 answers

Sort by ┬╗ oldest newest most voted
1

answered 2017-01-10 15:49:00 -0500

updated 2017-01-10 15:49:30 -0500

The "no valid hosts" found error is caused by the enabled nova filters in /etc/nova/nova.conf which the nova-scheduler uses in its algorithm deciding where to place instances at provisioning time. (This is called scheduling the instance). These filters can reject hypervisors based on the filter criteria. Enabling debug logging in nova, then re-trying the provision is the best way to see which filter shows as returning 0 hosts for scheduling.

Once the debug logging is enabled and nova has been restarted, grep the nova-scheduler.log file for "Filter", or tail -f the file as you provision the instance. In an HA environment, you'll need to tail the file on each controller, as the request may go to any of the running nova-scheduler processes.

You can get more info on the nova schedulers here: http://docs.openstack.org/newton/config-reference/compute/schedulers.html

edit flag offensive delete link more
1

answered 2016-10-11 03:15:06 -0500

peter.slovak gravatar image

You can turn on debug=True on the controller node in nova.conf, that way you'll be able to see which filter of the scheduler returns 0 hosts. That's the place you should look into - for example, if the first filter returning 0 suitable hosts is ComputeCapabilitiesFilter, you should look at the flavor metadata and search for properties like "ssd=True" that are not compatible with any of your compute nodes. If the filter is RamFilter, it's obvious - not enough RAM on the compute node.

Alternatively, you can also edit the particular filter's code to log more details about why the host didn't pass.

If you are just playing around and don't need advanced scheduling, use Chance scheduler instead of Filter scheduler. In this case, you rule out metadata mismatches and will only get the error if something resource-related went wrong (e.g. not enough RAM or HDD, as already mentioned). See http://docs.openstack.org/mitaka/conf...

edit flag offensive delete link more
0

answered 2016-11-23 10:07:38 -0500

I have the same problem but i can created 2-4 instance┬┤s before!

Error: "No valid host was found. There are not enough hosts available." it is equal what flavor i use. The compute node have absolut enough resources and no limits in the quotes.

What can i do? I use newton.

edit flag offensive delete link more

Comments

the system has checked the compute host of enough disk place. i must created correct instances with the cinder. (-.-)

peterlustig gravatar imagepeterlustig ( 2016-12-13 05:11:50 -0500 )edit
0

answered 2016-10-10 07:58:45 -0500

thewizardofOZ gravatar image

The compute node might not have enough cpu or memory. Check the flavor you choose and system sources.

edit flag offensive delete link more
0

answered 2016-09-23 06:29:02 -0500

Sudhin gravatar image

Hi,

Just check the neutron agents are active .

neutron agent-list

edit flag offensive delete link more

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: 2016-09-17 07:15:26 -0500

Seen: 858 times

Last updated: Jan 10