yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #94770
[Bug 2076089] Re: admin cannot force instance launch on disabled host
I am sorry to be pedantic, but I would like to understand.
I have been using admin credentials and force instance creation for
several years as part of hypervisor testing workflows, leveraging the
ability to skip the run of the scheduling filters as described also in
the latest nova admin documetation
https://docs.openstack.org/nova/latest/admin/availability-
zones.html#using-availability-zones-to-select-hosts (thus being able to
schedule on disabled host)
So either the documentation is wrong, and this was a bug until it was
fixed in ZED, so the documentation needs to be updated, but it really
looks like a valid bug to me....
** Changed in: nova
Status: Invalid => Confirmed
** Changed in: nova
Status: Confirmed => New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/2076089
Title:
admin cannot force instance launch on disabled host
Status in OpenStack Compute (nova):
New
Bug description:
Description
===========
I have a set of disabled nova compute services, with nova compute service up and running, and I would like to force instance creation, as admin, on a disabled conpute node for testing purposes.
I added the option --availability-zone nova:$HOST to the openstack
server create command, however it fails with "no valid host found"
even if it should have skipped placement filters.
Steps to reproduce
==================
* openstack compute service list --service nova-compute
+--------------------------------------+--------------+--------------+------+----------+-------+----------------------------+
| ID | Binary | Host | Zone | Status | State | Updated At |
+--------------------------------------+--------------+--------------+------+----------+-------+----------------------------+
| cdfe3225-a705-4c30-9f1b-a34be15d89a0 | nova-compute | test1-cg0001 | nova | disabled | down | 2024-07-18T16:03:00.000000 |
| f44ad40d-b161-48b0-914a-738638dc10ea | nova-compute | test1-c0001 | nova | enabled | up | 2024-08-05T09:57:08.000000 |
| 3e15725b-6b9d-44e9-ae03-fe121d75017c | nova-compute | test1-c0003 | nova | disabled | up | 2024-08-05T09:57:05.000000 |
+--------------------------------------+--------------+--------------+------+----------+-------+----------------------------+
* openstack server create --wait --flavor 016016 --boot-from-volume 20 --image "Debian 12 (Switch Cloud)" --network my_private_network --availability-zone nova:test1-c0003 strider-force-launch
Error creating server: strider-force-launch
Error creating server
Expected result
===============
Launch process should have skipped placement filters and instance should have been launched on requested hypervisor
Actual result
=============
* Failure reason is "No valid host found":
openstack server show strider-force-launch
+-------------------------------------+-------------------------------------------------------------------------------------------------------+
| Field | Value |
+-------------------------------------+-------------------------------------------------------------------------------------------------------+
| OS-DCF:diskConfig | MANUAL |
| OS-EXT-AZ:availability_zone | nova |
| OS-EXT-SRV-ATTR:host | None |
| OS-EXT-SRV-ATTR:hypervisor_hostname | None |
| OS-EXT-SRV-ATTR:instance_name | instance-00001256 |
| OS-EXT-STS:power_state | NOSTATE |
| OS-EXT-STS:task_state | None |
| OS-EXT-STS:vm_state | error |
| OS-SRV-USG:launched_at | None |
| OS-SRV-USG:terminated_at | None |
| accessIPv4 | |
| accessIPv6 | |
| addresses | |
| config_drive | |
| created | 2024-08-05T10:03:36Z |
| fault | {'code': 500, 'created': '2024-08-05T10:03:38Z', 'message': 'No valid host was found. ', 'details': |
| | 'Traceback (most recent call last):\n File "/var/lib/openstack/lib/python3.8/site- |
| | packages/nova/conductor/manager.py", line 1654, in schedule_and_build_instances\n host_lists = |
| | self._schedule_instances(context, request_specs[0],\n File "/var/lib/openstack/lib/python3.8/site- |
| | packages/nova/conductor/manager.py", line 942, in _schedule_instances\n host_lists = |
| | self.query_client.select_destinations(\n File "/var/lib/openstack/lib/python3.8/site- |
| | packages/nova/scheduler/client/query.py", line 41, in select_destinations\n return |
| | self.scheduler_rpcapi.select_destinations(context, spec_obj,\n File |
| | "/var/lib/openstack/lib/python3.8/site-packages/nova/scheduler/rpcapi.py", line 160, in |
| | select_destinations\n return cctxt.call(ctxt, \'select_destinations\', **msg_args)\n File |
| | "/var/lib/openstack/lib/python3.8/site-packages/oslo_messaging/rpc/client.py", line 190, in call\n |
| | result = self.transport._send(\n File "/var/lib/openstack/lib/python3.8/site- |
| | packages/oslo_messaging/transport.py", line 123, in _send\n return self._driver.send(target, ctxt, |
| | message,\n File "/var/lib/openstack/lib/python3.8/site- |
| | packages/oslo_messaging/_drivers/amqpdriver.py", line 689, in send\n return self._send(target, |
| | ctxt, message, wait_for_reply, timeout,\n File "/var/lib/openstack/lib/python3.8/site- |
| | packages/oslo_messaging/_drivers/amqpdriver.py", line 681, in _send\n raise |
| | result\nnova.exception_Remote.NoValidHost_Remote: No valid host was found. \nTraceback (most recent |
| | call last):\n\n File "/var/lib/openstack/lib/python3.8/site-packages/oslo_messaging/rpc/server.py", |
| | line 244, in inner\n return func(*args, **kwargs)\n\n File |
| | "/var/lib/openstack/lib/python3.8/site-packages/nova/scheduler/manager.py", line 210, in |
| | select_destinations\n raise exception.NoValidHost(reason="")\n\nnova.exception.NoValidHost: No |
| | valid host was found. \n\n'} |
| flavor | c016r016 (016016) |
| hostId | |
| id | cf06d1ed-23a7-42ea-afe3-b7e1ae73d2c4 |
| image | N/A (booted from volume) |
| key_name | None |
| name | strider-force-launch |
| project_id | 33b32a0cd27e4b54b128a21c4a97f8f0 |
| properties | |
| status | ERROR |
| updated | 2024-08-05T10:03:38Z |
| user_id | e82a4513cfad4b48af8acd3a8a60c579 |
| volumes_attached | |
+-------------------------------------+-------------------------------------------------------------------------------------------------------+
Environment
===========
1. Tested on Openstack ANTELOPE (nova version 27.2.1). Reproducible also on ZED (nova version 26.2.3)
2. Hypervisor type: Libvirt 8.0 + KVM
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/2076089/+subscriptions
References